Class AttributeMap

    • Method Detail

      • containsKey

        public <T> boolean containsKey​(AttributeMap.Key<T> typedKey)
        Return true if the provided key is configured in this map. Useful for differentiating between whether the provided key was not configured in the map or if it is configured, but its value is null.
      • get

        public <T> T get​(AttributeMap.Key<T> key)
        Get the value associated with the provided key from this map. This will return null if the value is not set or if the value stored is null. These cases can be disambiguated using containsKey(Key).
      • merge

        public AttributeMap merge​(AttributeMap lowerPrecedence)
        Merges two AttributeMaps into one. This object is given higher precedence then the attributes passed in as a parameter.
        Parameters:
        lowerPrecedence - Options to merge into 'this' AttributeMap object. Any attribute already specified in 'this' object will be left as is since it has higher precedence.
        Returns:
        New options with values merged.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object