// AttrNames returns a sorted list of names for an attribute set.
161775
func AttrNames(attrs map[string]interface{}) []string {
	a := make([]string, 0, len(attrs))
	for k := range attrs {
		a = append(a, k)
	}
	sort.Strings(a)
	return a
}
56893
func (s *DeleteUserAttributesInput) SetUserAttributeNames(v []*string) *DeleteUserAttributesInput {
	s.UserAttributeNames = v
	return s
}
17546
func (h *HTMLElement) Attr(k string) string {
	for _, a := range h.attributes {
		if a.Key == k {
			return a.Val
		}
	}
	return ""
}
878677
func (s *GetPlatformApplicationAttributesOutput) SetAttributes(v map[string]*string) *GetPlatformApplicationAttributesOutput {
	s.Attributes = v
	return s
}
918445
func (r *ruleImpl) Attr(name string) (starlark.Value, error) {
	switch name {
	case "defaults":
		return r.defaults, nil
	default:
		return nil, nil
	}
}
968581
func (s *ThingDocument) SetAttributes(v map[string]*string) *ThingDocument {
	s.Attributes = v
	return s
}
1367230
func (s *GetSMSAttributesOutput) SetAttributes(v map[string]*string) *GetSMSAttributesOutput {
	s.Attributes = v
	return s
}
556619
func (s *PutAttributesInput) SetAttributes(v []*ReplaceableAttribute) *PutAttributesInput {
	s.Attributes = v
	return s
}
536074
func (s *DeletableItem) SetAttributes(v []*DeletableAttribute) *DeletableItem {
	s.Attributes = v
	return s
}
356716
func Attr(selectorName string, ifAddrsRaw interface{}) (string, error) {
	switch v := ifAddrsRaw.(type) {
	case sockaddr.IfAddr:
		return sockaddr.IfAttr(selectorName, v)
	case sockaddr.IfAddrs:
		return sockaddr.IfAttrs(selectorName, v)
	default:
		return "", fmt.Errorf("unable to obtain attribute %s from type %T (%v)", selectorName, ifAddrsRaw, ifAddrsRaw)
	}
}
1336721
func (s *SetSMSAttributesInput) SetAttributes(v map[string]*string) *SetSMSAttributesInput {
	s.Attributes = v
	return s
}
72151
func (v *InstancesView) AllAttributes() []Attribute {

	if v.attrs == nil {
		return v.src.AllAttributes()
	}

	ret := make([]Attribute, len(v.attrs))

	for i, a := range v.attrs {
		ret[i] = a.GetAttribute()
	}

	return ret
}
523896
func (c *ServiceCurve) Attrs() (uint32, uint32, uint32) {
	return c.m1, c.d, c.m2
}
565051
func (s *GetLinkAttributesOutput) SetAttributes(v []*AttributeKeyAndValue) *GetLinkAttributesOutput {
	s.Attributes = v
	return s
}
1184486
func (s *GetQueueAttributesInput) SetAttributeNames(v []*string) *GetQueueAttributesInput {
	s.AttributeNames = v
	return s
}
1026697
func (a *Attributes) Names() []string {
	i := 0
	names := make([]string, len(a.Attrs))
	for name := range a.Attrs {
		names[i] = name
		i++
	}
	return names
}
1130573
func (base Base) Attrs() string {
	var ret string

	if base.ID != "" {
		ret += " id='" + base.ID + "'"
	}

	//Classes
	if len(base.Classes) != 0 {
		ret += " class='"
		ret += strings.Join(base.Classes, " ")
		ret += "'"
	}

	//Style
	if len(base.Style) != 0 {
		ret += " style='"
		var keys []string
		for key := range base.Style {
			keys = append(keys, key)
		}
		sort.Strings(keys)
		for _, val := range keys {
			ret += val + ":" + base.Style[val] + ";"
		}
		ret += "'"
	}

	var keys []string
	for key := range base.Data {
		keys = append(keys, key)
	}
	sort.Strings(keys)
	for _, key := range keys {
		ret += " " + key + "='" + base.Data[key] + "'"
	}

	return ret
}