// ExtractUnretrievableAttributes returns the first found UnretrievableAttributesOption from the
// given variadic arguments or nil otherwise.
557842
func ExtractUnretrievableAttributes(opts ...interface{}) *opt.UnretrievableAttributesOption {
	for _, o := range opts {
		if v, ok := o.(*opt.UnretrievableAttributesOption); ok {
			return v
		}
	}
	return nil
}
968920
func (c *ChiMergeFilter) GetAttributesAfterFiltering() []base.FilteredAttribute {
	oldAttrs := c.train.AllAttributes()
	ret := make([]base.FilteredAttribute, len(oldAttrs))
	for i, a := range oldAttrs {
		if c.attrs[a] {
			retAttr := new(base.CategoricalAttribute)
			retAttr.SetName(a.GetName())
			for _, k := range c.tables[a] {
				retAttr.GetSysValFromString(fmt.Sprintf("%f", k.Value))
			}
			ret[i] = base.FilteredAttribute{a, retAttr}
		} else {
			ret[i] = base.FilteredAttribute{a, a}
		}
	}
	return ret
}
115265
func ExtractDisableTypoToleranceOnWords(opts ...interface{}) *opt.DisableTypoToleranceOnWordsOption {
	for _, o := range opts {
		if v, ok := o.(*opt.DisableTypoToleranceOnWordsOption); ok {
			return v
		}
	}
	return nil
}
1018008
func UnmarshalList(l []*dynamodb.AttributeValue, out interface{}) error {
	return NewDecoder().Decode(&dynamodb.AttributeValue{L: l}, out)
}
448931
func (mgr *Mgr) GetAttributesFromCert(cert *x509.Certificate) (*Attributes, error) {
	// Get certificate attributes from the certificate if it exists
	buf, err := getAttributesFromCert(cert)
	if err != nil {
		return nil, err
	}
	// Unmarshal into attributes object
	attrs := &Attributes{}
	if buf != nil {
		err := json.Unmarshal(buf, attrs)
		if err != nil {
			return nil, errors.Wrap(err, "Failed to unmarshal attributes from certificate")
		}
	}
	return attrs, nil
}
890458
func ExtractReferers(opts ...interface{}) *opt.ReferersOption {
	for _, o := range opts {
		if v, ok := o.(*opt.ReferersOption); ok {
			return v
		}
	}
	return nil
}
1281202
func ExtractAttributeForDistinct(opts ...interface{}) *opt.AttributeForDistinctOption {
	for _, o := range opts {
		if v, ok := o.(*opt.AttributeForDistinctOption); ok {
			return v
		}
	}
	return nil
}
1306993
func (r Account) GetAttributes() (resp []datatypes.Account_Attribute, err error) {
	err = r.Session.DoRequest("SoftLayer_Account", "getAttributes", nil, &r.Options, &resp)
	return
}
192281
func untarFunc(i interface{}) containerfs.UntarFunc {
	if ea, ok := i.(extractor); ok {
		return ea.ExtractArchive
	}
	return chrootarchive.Untar
}
1036496
func ExtractEnablePersonalization(opts ...interface{}) *opt.EnablePersonalizationOption {
	for _, o := range opts {
		if v, ok := o.(*opt.EnablePersonalizationOption); ok {
			return v
		}
	}
	return nil
}
98552
func (m *Mat64Instances) GetAttribute(a Attribute) (AttributeSpec, error) {
	for i, at := range m.attributes {
		if at.Equals(a) {
			return AttributeSpec{0, i, at}, nil
		}
	}
	return AttributeSpec{}, fmt.Errorf("Couldn't find a matching attribute")
}
448955
func ExtractAttributesToSnippet(opts ...interface{}) *opt.AttributesToSnippetOption {
	for _, o := range opts {
		if v, ok := o.(*opt.AttributesToSnippetOption); ok {
			return v
		}
	}
	return nil
}
853053
func (a customResourceStrategy) GetAttrs(obj runtime.Object) (labels.Set, fields.Set, error) {
	accessor, err := meta.Accessor(obj)
	if err != nil {
		return nil, nil, err
	}
	return labels.Set(accessor.GetLabels()), objectMetaFieldsSet(accessor, a.namespaceScoped), nil
}
304508
func ExtractKeepDiacriticsOnCharacters(opts ...interface{}) *opt.KeepDiacriticsOnCharactersOption {
	for _, o := range opts {
		if v, ok := o.(*opt.KeepDiacriticsOnCharactersOption); ok {
			return v
		}
	}
	return nil
}
978962
func DecodeAttrs(v []byte) (map[string]interface{}, error) {
	var pb internal.AttrMap
	if err := proto.Unmarshal(v, &pb); err != nil {
		return nil, err
	}
	return decodeAttrs(pb.GetAttrs()), nil
}
1338927
func UnmarshalAttributes(b []byte) ([]Attribute, error) {
	var attrs []Attribute
	var i int
	for {
		if i > len(b) || len(b[i:]) == 0 {
			break
		}

		var a Attribute
		if err := (&a).unmarshal(b[i:]); err != nil {
			return nil, err
		}

		if a.Length == 0 {
			i += nlaHeaderLen
			continue
		}

		i += nlaAlign(int(a.Length))

		attrs = append(attrs, a)
	}

	return attrs, nil
}
921787
func (a *saOAuthClientAdapter) extractRedirectURIs(modelsMap map[string]model, namespace string) (redirectURIList, []error) {
	var data redirectURIList
	routeErrors := []error{}
	groupKindModelListMapper := map[schema.GroupKind]modelList{} // map of GroupKind to all models belonging to it
	groupKindModelToURI := map[schema.GroupKind]namesToObjMapperFunc{
		routeGroupKind: a.redirectURIsFromRoutes,
		// TODO add support for ingresses by creating the appropriate GroupKind and namesToObjMapperFunc
		// ingressGroupKind: a.redirectURIsFromIngresses,
	}

	for _, m := range modelsMap {
		gk := m.getGroupKind()
		if gk == legacyRouteGroupKind {
			gk = routeGroupKind // support legacy route group without doing extra API calls
		}
		if len(m.name) == 0 && gk == emptyGroupKind { // Is this a static redirect URI?
			uri := redirectURI{} // No defaults wanted
			uri.merge(&m)
			data = append(data, uri)
		} else if _, ok := groupKindModelToURI[gk]; ok { // a GroupKind is valid if we have a namesToObjMapperFunc to handle it
			groupKindModelListMapper[gk] = append(groupKindModelListMapper[gk], m)
		}
	}

	for gk, models := range groupKindModelListMapper {
		if names := models.getNames(); names.Len() > 0 {
			objMapper, errs := groupKindModelToURI[gk](namespace, names)
			if len(objMapper) > 0 {
				data = append(data, models.getRedirectURIs(objMapper)...)
			}
			if len(errs) > 0 {
				routeErrors = append(routeErrors, errs...)
			}
		}
	}

	return data, routeErrors
}