Class InplaceEditingConfig


  • public class InplaceEditingConfig
    extends java.lang.Object
    Implements the basic inplace editing configuration.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String NN_CONFIG_DEFAULT
      Default path to the editor-specific config node
      static java.lang.String PN_ACTIVE
      Name of property containing the flag if inplace editing is active
      static java.lang.String PN_CONFIG_PATH
      Name of property containing the path to the editor's configuration node
      static java.lang.String PN_EDITOR_TYPE
      Name of property containing the inplace editor's type
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Map<java.lang.String,​ChildEditor> getChildEditors()
      Returns a unmodifiable map of configurations of inplace child editors.
      java.lang.String getConfigPath()
      Gets the path to the editor-specific configuration.
      java.lang.String getEditorType()
      Gets the type of inplace editor to be used.
      boolean isActive()
      Determines if inplace editing is active for this component.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • PN_ACTIVE

        public static final java.lang.String PN_ACTIVE
        Name of property containing the flag if inplace editing is active
        See Also:
        Constant Field Values
      • PN_EDITOR_TYPE

        public static final java.lang.String PN_EDITOR_TYPE
        Name of property containing the inplace editor's type
        See Also:
        Constant Field Values
      • PN_CONFIG_PATH

        public static final java.lang.String PN_CONFIG_PATH
        Name of property containing the path to the editor's configuration node
        See Also:
        Constant Field Values
      • NN_CONFIG_DEFAULT

        public static final java.lang.String NN_CONFIG_DEFAULT
        Default path to the editor-specific config node
        See Also:
        Constant Field Values
    • Constructor Detail

      • InplaceEditingConfig

        public InplaceEditingConfig​(Node configNode)
                             throws RepositoryException
        Creates a new basic inplace editing configuration from the given configuration Node.
        Parameters:
        configNode - The node to generate the basic configuration from.
        Throws:
        RepositoryException - This exception is thrown for repository access related issues.
      • InplaceEditingConfig

        public InplaceEditingConfig​(InplaceEditingConfig config)
        Creates a new basic inplace editing configuration from the specified configuration.
        Parameters:
        config - Existing configuration to clone
    • Method Detail

      • isActive

        public boolean isActive()
        Determines if inplace editing is active for this component.
        Returns:
        true if inplace editing is active for this component
      • getEditorType

        public java.lang.String getEditorType()
        Gets the type of inplace editor to be used. The returned String must match a inplace editor module that is registered clientside under that type. Note that isActive will return false if no inplace editing module is specified (and getInplaceEditor will return null)
        Returns:
        Type of the inplace module; null if no inplace editing module is defined
      • getConfigPath

        public java.lang.String getConfigPath()
        Gets the path to the editor-specific configuration. The editor will use this path to load its configuration through an JSON request accordingly. Note that there must not necessarily be a node at the specified path; hence the clientside implementation must internally use suitable default values
        Returns:
        Path to the configuration node
      • getChildEditors

        public java.util.Map<java.lang.String,​ChildEditor> getChildEditors()
        Returns a unmodifiable map of configurations of inplace child editors. the keys are the ids of the configs.
        Returns:
        map of inplace child editors configurations.