// Bindings prints the bindings from r to w.
10089
func Bindings(w io.Writer, r Output) error {
	if r.Error != nil {
		return prettyError(w, r.Error)
	}
	for _, rs := range r.Result {
		if err := JSON(w, rs.Bindings); err != nil {
			return err
		}
	}
	return nil
}
460949
func (s *IndicesRolloverService) Mappings(mappings map[string]interface{}) *IndicesRolloverService {
	s.mappings = mappings
	return s
}
1073628
func (c *GraphClause) Bindings() []string {
	var bs []string
	for k := range c.BindingsMap() {
		bs = append(bs, k)
	}
	return bs
}
1131762
func (s *RemoteApplication) Bindings() map[string]string {
	result := make(map[string]string)
	for epName, spName := range s.doc.Bindings {
		result[epName] = spName
	}
	return result
}
478691
func Convert_v1_Binding_To_core_Binding(in *v1.Binding, out *core.Binding, s conversion.Scope) error {
	return autoConvert_v1_Binding_To_core_Binding(in, out, s)
}
1284657
func (BasePage) ReadSettings(c context.Context) (map[string]string, error) {
	return nil, nil
}
256328
func BindFields(obj interface{}) Fields {
	t := reflect.TypeOf(obj)
	v := reflect.ValueOf(obj)
	fields := make(map[string]*Field)

	if t.Kind() == reflect.Ptr {
		t = t.Elem()
		v = v.Elem()
	}

	for i := 0; i < t.NumField(); i++ {
		field := t.Field(i)

		tag := extractTag(field.Tag)
		if tag == "-" {
			continue
		}

		fieldType := field.Type

		if fieldType.Kind() == reflect.Ptr {
			fieldType = fieldType.Elem()
		}

		var graphType Output
		if fieldType.Kind() == reflect.Struct {
			structFields := BindFields(v.Field(i).Interface())

			if tag == "" {
				fields = appendFields(fields, structFields)
				continue
			} else {
				graphType = NewObject(ObjectConfig{
					Name:   tag,
					Fields: structFields,
				})
			}
		}

		if tag == "" {
			continue
		}

		if graphType == nil {
			graphType = getGraphType(fieldType)
		}
		fields[tag] = &Field{
			Type: graphType,
			Resolve: func(p ResolveParams) (interface{}, error) {
				return extractValue(tag, p.Source), nil
			},
		}
	}
	return fields
}
313176
func addBindings(a, b bindingFrame) bindingFrame {
	result := make(bindingFrame)

	for k, v := range a {
		result[k] = v
	}

	for k, v := range b {
		result[k] = v
	}

	return result
}
422132
func (s *Statement) InputBindings() []string {
	var res []string
	for _, p := range s.projection {
		if p.Binding != "" {
			res = append(res, p.Binding)
		}
	}
	for _, c := range s.constructClauses {
		if c.SBinding != "" {
			res = append(res, c.SBinding)
		}
		for _, p := range c.predicateObjectPairs {
			if p.PBinding != "" {
				res = append(res, p.PBinding)
			}
			if p.PAnchorBinding != "" {
				res = append(res, p.PAnchorBinding)
			}
			if p.OBinding != "" {
				res = append(res, p.OBinding)
			}
			if p.OAnchorBinding != "" {
				res = append(res, p.OAnchorBinding)
			}
		}
	}
	return res
}
488180
func (ctx *ContextRelation) WriteSettings() (err error) {
	if ctx.settings != nil {
		err = ctx.settings.Write()
	}
	return
}
716248
func (c *Context) BindWith(obj interface{}, b binding.Binding) error {
	log.Println(`BindWith(\"interface{}, binding.Binding\") error is going to
	be deprecated, please check issue #662 and either use MustBindWith() if you
	want HTTP 400 to be automatically returned if any error occur, or use
	ShouldBindWith() if you need to manage the error.`)
	return c.MustBindWith(obj, b)
}
561445
func BindOverrideFlags(overrides *ConfigOverrides, flags *pflag.FlagSet, flagNames ConfigOverrideFlags) {
	BindAuthInfoFlags(&overrides.AuthInfo, flags, flagNames.AuthOverrideFlags)
	BindClusterFlags(&overrides.ClusterInfo, flags, flagNames.ClusterOverrideFlags)
	BindContextFlags(&overrides.Context, flags, flagNames.ContextOverrideFlags)
	flagNames.CurrentContext.BindStringFlag(flags, &overrides.CurrentContext)
}
584059
func (c *Client) DeleteBinding(vhost string, info BindingInfo) (res *http.Response, err error) {
	req, err := newRequestWithBody(c, "DELETE", "bindings/"+PathEscape(vhost)+
		"/e/"+PathEscape(info.Source)+"/"+PathEscape(string(info.DestinationType[0]))+
		"/"+PathEscape(info.Destination)+"/"+PathEscape(info.PropertiesKey), nil)
	if err != nil {
		return nil, err
	}

	res, err = executeRequest(c, req)
	if err != nil {
		return nil, err
	}

	return res, nil
}
214579
func CoerceStrings(v interface{}) []string {
	switch val := v.(type) {
	case string:
		if val == "" {
			return nil
		}
		return strings.Split(val, ",")
	case []string:
		return val
	case []interface{}:
		sva := make([]string, 0)
		for _, av := range val {
			switch aval := av.(type) {
			case string:
				sva = append(sva, aval)
			default:
				sv, err := CoerceString(av)
				if err == nil && sv != "" {
					sva = append(sva, sv)
				}
			}
		}
		return sva
	}
	return []string{CoerceStringShort(v)}
}
161167
func (c *Client) ListBindingsIn(vhost string) (rec []BindingInfo, err error) {
	return c.listBindingsVia("bindings/" + PathEscape(vhost))
}
136792
func (f *Factory) BindFlags(flags *pflag.FlagSet) {
	// any flags defined by external projects (not part of pflags)
	flags.AddGoFlagSet(flag.CommandLine)

	// Merge factory's flags
	flags.AddFlagSet(f.flags)

	// Globally persistent flags across all subcommands.
	// TODO Change flag names to consts to allow safer lookup from subcommands.
	// TODO Add a verbose flag that turns on glog logging. Probably need a way
	// to do that automatically for every subcommand.
	flags.BoolVar(&f.clients.matchVersion, FlagMatchBinaryVersion, false, "Require server version to match client version")

	// Normalize all flags that are coming from other packages or pre-configurations
	// a.k.a. change all "_" to "-". e.g. glog package
	flags.SetNormalizeFunc(util.WordSepNormalizeFunc)
}
407903
func (o *FilterOptions) Bind(flags *pflag.FlagSet) {
	flags.StringVar(&o.FilterByOS, "filter-by-os", o.FilterByOS, "A regular expression to control which images are considered when multiple variants are available. Images will be passed as '<platform>/<architecture>[/<variant>]'.")
}