Class InplaceEditingConfig

java.lang.Object
com.day.cq.wcm.api.components.InplaceEditingConfig

public class InplaceEditingConfig extends Object
Implements the basic inplace editing configuration.
  • Field Details

    • PN_ACTIVE

      public static final String PN_ACTIVE
      Name of property containing the flag if inplace editing is active
      See Also:
    • PN_EDITOR_TYPE

      public static final String PN_EDITOR_TYPE
      Name of property containing the inplace editor's type
      See Also:
    • PN_CONFIG_PATH

      public static final String PN_CONFIG_PATH
      Name of property containing the path to the editor's configuration node
      See Also:
    • NN_CONFIG_DEFAULT

      public static final String NN_CONFIG_DEFAULT
      Default path to the editor-specific config node
      See Also:
  • Constructor Details

    • 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 Details

    • 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 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 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 Map<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.