addWithMap method
Adds a value to the counter's sum using a map of attributes.
value The increment amount, can be positive or negative.
attributeMap A map of attribute key-value pairs.
Implementation
void addWithMap(T value, Map<String, Object> attributeMap) {
// Convert map to Attributes and delegate to add
final attributes =
attributeMap.isEmpty ? null : attributeMap.toAttributes();
add(value, attributes);
}