AttributesEditor
Package: com.salesforce.marketingcloud.sfmcsdk.components.identity
Platform: androidJvm
The AttributesEditor class wraps the Identity.Builder attribute map functions to provide an idiomatic Kotlin syntax for managing user attributes in the Salesforce Marketing Cloud SDK.
Creates an instance that wraps an Identity.Builder for attribute operations.
Parameters:
builder- The Identity.Builder instance to wrap
Clears the value of the specified attributes, effectively setting them to null.
Parameters:
keys- Variable number of attribute keys to clear
Clears the value of the specified attributes, effectively setting them to null.
Parameters:
keys- List of attribute keys to clear
Clears the value of the specified attribute, effectively setting it to null.
Parameters:
key- The attribute key to clear
Clears the value of all attributes, effectively setting them to null.
Updates or adds the value of an entry for the given key in the attribute map using the += operator.
Parameters:
entry- A Pair containing the key and nullable value to add/update
Updates or adds the value of an entry for the given key in the attribute map.
Parameters:
key- The attribute keyvalue- The nullable attribute value
Updates or adds all the values from the passed in map.
Parameters:
from- Map of attributes to add/update
First clears the values of all existing attributes. Then updates or adds the values from the passed in map.
Note: Attribute keys cannot be removed, only the value can be cleared or set to null.
Parameters:
from- Map of attributes to set
Updates or adds the value of an entry for the given key in the attribute map using array-style indexing syntax.
Parameters:
key- The attribute keyvalue- The nullable attribute value