Class Decoration

    • Constructor Detail

      • Decoration

        protected Decoration()
        Instantiates a default Decoration instance (obviously only callable by subclasses).
    • Method Detail

      • applyDecoration

        public abstract Node applyDecoration​(Node targetNode)
        This method decorates the given target node with the relevant decorations, returning any 'decoration node' that needs to be added to the scenegraph (although this can be null). When the returned Node is null, this indicates that the decoration will be handled internally by the decoration (which is preferred, as the default implementation is not ideal in most circumstances).

        When the boolean parameter is false, this method removes the decoration from the given target node, always returning null.

        Parameters:
        targetNode - The node to decorate.
        Returns:
        The decoration, but null is a valid return value.
      • removeDecoration

        public abstract void removeDecoration​(Node targetNode)
        This method removes the decoration from the given target node.
        Parameters:
        targetNode - The node to undecorate.
      • getProperties

        public final Map<String,​Object> getProperties()
        Custom decoration properties
        Returns:
        decoration properties