[#BloombergLP-ball-ManagedAttributeSet] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/ball.adoc[ball]::ManagedAttributeSet :relfileprefix: ../../ :mrdocs: This class implements a value‐semantic collection of unique attributes. (Note that an attribute is a compound entity that, as a whole, must be unique although individual parts need not be.) Additionally, the `evaluate` accessor can be used to determine if every attribute in the set is present in the specified attribute container list. == Synopsis Declared in `<ball_managedattributeset.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- class ManagedAttributeSet; ---- == Type Aliases [cols="1,4"] |=== | Name| Description | xref:BloombergLP/ball/ManagedAttributeSet/allocator_type.adoc[`allocator_type`] | This `typedef` is an alias for the allocator used by this object. | xref:BloombergLP/ball/ManagedAttributeSet/const_iterator.adoc[`const_iterator`] | This `typedef` is an alias for a constant iterator over the managed attribute set. |=== == Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/ball/ManagedAttributeSet/2constructor-0e.adoc[`ManagedAttributeSet`] [.small]#[constructor]# | Constructors | xref:BloombergLP/ball/ManagedAttributeSet/operator_assign.adoc[`operator=`] | Assign the value of the specified `rhs` to this object, and return a reference providing modifiable access to this object. | xref:BloombergLP/ball/ManagedAttributeSet/addAttribute.adoc[`addAttribute`] | Add an attribute having the specified `value` to this object. Return `true` on success and `false` if an attribute having the same `value` already exists in this object. | xref:BloombergLP/ball/ManagedAttributeSet/addPredicate.adoc[`addPredicate`] | Add an attribute having the specified `value` to this object. Return 1 on success and 0 if an attribute having the same value already exists in this object. | xref:BloombergLP/ball/ManagedAttributeSet/begin.adoc[`begin`] | Return an iterator referring to the first member of this attribute set. | xref:BloombergLP/ball/ManagedAttributeSet/end.adoc[`end`] | Return an iterator referring to one past the last member of this attribute set. | xref:BloombergLP/ball/ManagedAttributeSet/evaluate.adoc[`evaluate`] | Return `true` if for every attribute maintained by this object, an attribute with the same name and value exists in the specified `containerList`, or if this object has no attributes; otherwise return `false`. | xref:BloombergLP/ball/ManagedAttributeSet/get_allocator.adoc[`get_allocator`] | Return the allocator used by this object to supply memory. Note that if no allocator was supplied at construction the default allocator in effect at construction is used. | xref:BloombergLP/ball/ManagedAttributeSet/isMember.adoc[`isMember`] | Return `true` if an attribute having specified `value` exists in this object, and `false` otherwise. | xref:BloombergLP/ball/ManagedAttributeSet/numAttributes.adoc[`numAttributes`] | Return the number of attributes managed by this object. | xref:BloombergLP/ball/ManagedAttributeSet/numPredicates.adoc[`numPredicates`] | DEPRECATED: Use `numAttributes` instead. | xref:BloombergLP/ball/ManagedAttributeSet/print.adoc[`print`] | Format this object to the specified output `stream` at the (absolute value of) the optionally specified indentation `level` and return a reference to `stream`. If `level` is specified, optionally specify `spacesPerLevel`, the number of spaces per indentation level for this and all of its nested objects. If `level` is negative, suppress indentation of the first line. If `spacesPerLevel` is negative, format the entire output on one line, suppressing all but the initial indentation (as governed by `level`). If `stream` is not valid on entry, this operation has no effect. | xref:BloombergLP/ball/ManagedAttributeSet/removeAll.adoc[`removeAll`] | Remove all attributes from this attribute set. | xref:BloombergLP/ball/ManagedAttributeSet/removeAllPredicates.adoc[`removeAllPredicates`] | DEPRECATED: Use `removeAll` instead. | xref:BloombergLP/ball/ManagedAttributeSet/removeAttribute.adoc[`removeAttribute`] | Remove the attribute having the specified `value` from this object. Return `true` on success and `false` if an attribute having the `value` does not exist in this object. | xref:BloombergLP/ball/ManagedAttributeSet/removePredicate.adoc[`removePredicate`] | Remove the attribute having the specified `value` from this object. Return the number of attributes removed (i.e., 1 on success and 0 if an attribute having `value` does not exist in this object). | xref:BloombergLP/ball/ManagedAttributeSet/2conversion.adoc[`operator BloombergLP::bslmf::NestedTraitDeclaration<ManagedAttributeSet, UsesBslmaAllocator>`] | Declare that this type uses a `bslma` allocator. |=== == Static Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/ball/ManagedAttributeSet/hash.adoc[`hash`] | Return a hash value calculated from the specified `set` using the specified `size` as the number of slots. The hash value is guaranteed to be in the range `[0 .. size ‐ 1]`. The behavior is undefined unless `0 < size`. |=== == Friends [cols="1,4"] |=== | Name| Description | `xref:BloombergLP/ball/operator_lshift-0cf9.adoc[BloombergLP::ball::operator<<]` | Write the value of the specified `attributeSet` to the specified `output` stream. Return the specified `output` stream. | `xref:BloombergLP/ball/operator_not_eq-0b6.adoc[BloombergLP::ball::operator!=]` | Return `true` if the specified `lhs` and `rhs` objects do not have the same value, and `false` otherwise. Two `ManagedAttributeSet` objects do not have the same value if they do not have the same number of attributes or there is at least one attribute value that appears in one object, but not in the other. | `xref:BloombergLP/ball/operator_eq-08e2.adoc[BloombergLP::ball::operator==]` | Return `true` if the specified `lhs` and `rhs` objects have the same value, and `false` otherwise. Two `ManagedAttributeSet` objects have the same value if they have the same number of attributes and every attribute value that appears in one object also appears in the other. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#