// HasConditionArg returns true if any arg is a conditional.
549097
func (c *Call) HasConditionArg() bool {
	for _, v := range c.Args {
		if _, ok := v.(*Condition); ok {
			return true
		}
	}
	return false
}
754167
func (s *IndicesRolloverService) AddCondition(name string, value interface{}) *IndicesRolloverService {
	s.conditions[name] = value
	return s
}
339141
func (p Protected) Has(key string) bool {
	_, ok := p[key]
	return ok
}
99248
func (p *Parser) parseCondition() (Expr, error) {
	// Check if the WHERE token exists.
	if tok, _, _ := p.ScanIgnoreWhitespace(); tok != WHERE {
		p.Unscan()
		return nil, nil
	}

	// Scan the identifier for the source.
	expr, err := p.ParseExpr()
	if err != nil {
		return nil, err
	}

	return expr, nil
}
649927
func (a Annotation) HasAll(expected map[string]string) bool {
	for k, v := range expected {
		if !a.Has(k, v) {
			return false
		}
	}
	return true
}
1012151
func (args Arguments) Is(objects ...interface{}) bool {
	for i, obj := range args {
		if obj != objects[i] {
			return false
		}
	}
	return true
}
1210602
func (a *ArgType) hasfield(fields []*Field, name string) bool {
	for _, f := range fields {
		if f.Name == name {
			return true
		}
	}

	return false
}
137296
func checkExclusive(ctx *cli.Context, args ...interface{}) {
	set := make([]string, 0, 1)
	for i := 0; i < len(args); i++ {
		// Make sure the next argument is a flag and skip if not set
		flag, ok := args[i].(cli.Flag)
		if !ok {
			panic(fmt.Sprintf("invalid argument, not cli.Flag type: %T", args[i]))
		}
		// Check if next arg extends current and expand its name if so
		name := flag.GetName()

		if i+1 < len(args) {
			switch option := args[i+1].(type) {
			case string:
				// Extended flag check, make sure value set doesn't conflict with passed in option
				if ctx.GlobalString(flag.GetName()) == option {
					name += "=" + option
					set = append(set, "--"+name)
				}
				// shift arguments and continue
				i++
				continue

			case cli.Flag:
			default:
				panic(fmt.Sprintf("invalid argument, not cli.Flag or string extension: %T", args[i+1]))
			}
		}
		// Mark the flag if it's set
		if ctx.GlobalIsSet(flag.GetName()) {
			set = append(set, "--"+name)
		}
	}
	if len(set) > 1 {
		Fatalf("Flags %v can't be used at the same time", strings.Join(set, ", "))
	}
}
817742
func IsPodReadyConditionTrue(status v1.PodStatus) bool {
	condition := GetPodReadyCondition(status)
	return condition != nil && condition.Status == v1.ConditionTrue
}
1166355
func (p *ProtoCommand) PreCondition(state State) bool {
	if p.PreConditionFunc != nil {
		return p.PreConditionFunc(state)
	}
	return true
}
734219
func HasColor(ctx context.Context) bool {
	_, ok := ctx.Value(ctxKeyColor).(bool)
	return ok
}
1278428
func isConditionCheckFailed(err error) bool {
	if err != nil {
		if err, ok := err.(awserr.Error); ok {
			return err.Code() == dynamodb.ErrCodeConditionalCheckFailedException
		}
	}

	return false
}
526267
func (e *loginProvision) checkArg() error {
	// check we have a good device type:
	if e.arg.DeviceType != libkb.DeviceTypeDesktop && e.arg.DeviceType != libkb.DeviceTypeMobile {
		return libkb.InvalidArgumentError{Msg: fmt.Sprintf("device type must be %q or %q, not %q", libkb.DeviceTypeDesktop, libkb.DeviceTypeMobile, e.arg.DeviceType)}
	}

	if e.arg.User == nil {
		return libkb.InvalidArgumentError{Msg: "User cannot be nil"}
	}

	return nil
}
561788
func (l Link) HasParam(key string) bool {
	for p := range l.Params {
		if p == key {
			return true
		}
	}
	return false
}
1094520
func (c *Config) Has(name string, idx int, options ...Option) (bool, error) {
	opts := makeOptions(options)
	p := parsePathIdx(name, opts.pathSep, idx)
	return p.Has(c, opts)
}
777105
func CheckFixedArgs(numArgs int, args []string) error {
	return CheckBoundedArgs(Bounds{Min: numArgs, Max: numArgs}, args)
}
1222468
func (a *SetBreakpointArgs) SetCondition(condition string) *SetBreakpointArgs {
	a.Condition = &condition
	return a
}