Class ElementStylePropertyMap

All Implemented Interfaces:
Serializable

public class ElementStylePropertyMap extends AbstractPropertyMap
Map for element style values.

For internal use only. May be renamed or removed in a future release.

Since:
1.0
Author:
Vaadin Ltd
See Also:
  • Constructor Details

    • ElementStylePropertyMap

      public ElementStylePropertyMap(StateNode node)
      Creates a new element style map for the given node.
      Parameters:
      node - the node that the map belongs to
  • Method Details

    • setProperty

      public void setProperty(String name, Serializable value, boolean emitChange)
      Description copied from class: AbstractPropertyMap
      Sets a property to the given value.
      Overrides:
      setProperty in class AbstractPropertyMap
      Parameters:
      name - the property name
      value - the value, must be a string, a boolean, a double or null
      emitChange - true to create a change event for the client side
    • setPropertyFromSignal

      public void setPropertyFromSignal(String name, Object value)
      Description copied from class: AbstractPropertyMap
      Applies a value coming from a signal to the property while preserving an existing binding.
      Specified by:
      setPropertyFromSignal in class AbstractPropertyMap
      Parameters:
      name - the property name
      value - the value to apply; null removes the property on the client but keeps the binding and last-applied value as null
    • get

      protected Serializable get(String key)
      Description copied from class: NodeMap
      Gets the value corresponding to the given key.
      Overrides:
      get in class NodeMap
      Parameters:
      key - the key to get a value for
      Returns:
      the value corresponding to the key; null if there is no value stored, or if null is stored as a value
    • removeAllProperties

      public void removeAllProperties()
      Description copied from class: AbstractPropertyMap
      Removes all properties.
      Overrides:
      removeAllProperties in class AbstractPropertyMap
    • hasProperty

      public boolean hasProperty(String name)
      Description copied from class: AbstractPropertyMap
      Checks whether there is a property of the given name.
      Overrides:
      hasProperty in class AbstractPropertyMap
      Parameters:
      name - the name of the property
      Returns:
      true if there is a property with the given name; false if there is no property
    • getStyle

      public Style getStyle()
      Returns a style instance for managing element inline styles.
      Returns:
      a Style instance connected to this map