Class DeviceAttributesManager

java.lang.Object
com.gimbal.android.DeviceAttributesManager

public class DeviceAttributesManager extends Object
Encrypts and stores key-value pairs
  • Constructor Details

    • DeviceAttributesManager

      public DeviceAttributesManager()
  • Method Details

    • getInstance

      public static DeviceAttributesManager getInstance()
    • getDeviceAttributes

      @NonNull public Map<String,String> getDeviceAttributes()
      Returns:
      Map of stored attributes if they exist, null if not.
    • setDeviceAttributes

      @Deprecated public void setDeviceAttributes(Map<String,String> deviceAttributes) throws IllegalArgumentException
      Deprecated.
      Replaces existing device attributes with a new list of attributes.
      Parameters:
      deviceAttributes - - the new attributes to replace old attributes with.
      Throws:
      IllegalArgumentException - - if one of the keys are reserved for internal use
    • setDeviceAttribute

      public void setDeviceAttribute(String key, String value) throws IllegalArgumentException
      Adds new attributes to device attributes
      Parameters:
      key - - the key of the new value
      value - - the value to store
      Throws:
      IllegalArgumentException - - if one of the keys are reserved for internal use
    • getDeviceAttribute

      @Nullable public String getDeviceAttribute(String key)
    • removeDeviceAttribute

      public void removeDeviceAttribute(String key)
      Removes a specific key-value pair from device attributes
      Parameters:
      key - the key of the key value pair that you wish to remove from device attributes