Class DragAndDropWebEditorStore

  • All Implemented Interfaces:
    Serializable, Nameable, Securable, SilverpeasResource

    public class DragAndDropWebEditorStore
    extends Object
    implements SilverpeasResource, Serializable, Securable
    Represents the store that register all data manipulated by a Drag & Drop Web Editor.

    The content is registered in Silverpeas's home data as structured XML file. The save MUST be explicitly performed by calling save() method.

    The structured content is divided into two parts:

    • a temporary part that permits to persists current edition and retrieve data whatever the context
    • a final part that represents the content to provide when data are validated

    Author:
    silveryocha
    See Also:
    Serialized Form
    • Constructor Detail

    • Method Detail

      • save

        public void save()
        Saves the structured content into Silverpeas's home data.
      • delete

        public boolean delete()
        Deletes the structured content into Silverpeas's home data. return true id deletion is well performed (false if file not exists)
      • getName

        public String getName()
        Description copied from interface: Nameable
        Gets the name of the object in Silverpeas.
        Specified by:
        getName in interface Nameable
        Returns:
        the name or the title of the object.
      • getDescription

        public String getDescription()
        Description copied from interface: Nameable
        Gets the description about the object in Silverpeas.
        Specified by:
        getDescription in interface Nameable
        Returns:
        a short description about the object.
      • getLastUpdateDate

        public Date getLastUpdateDate()
        Description copied from interface: SilverpeasResource
        Gets the date at which the resource has been lastly updated. If the resource doesn't have such an information, then this method should return the date of the resource creation.
        Specified by:
        getLastUpdateDate in interface SilverpeasResource
        Returns:
        the date of the last update of the resource.
      • getLastUpdater

        public User getLastUpdater()
        Description copied from interface: SilverpeasResource
        Gets the user that has lastly updated the resource. If the resource doesn't have such an information, then this method should return the user that has created the resource.
        Specified by:
        getLastUpdater in interface SilverpeasResource
        Returns:
        a User in Silverpeas.
      • getDirectoryPath

        public Path getDirectoryPath()
        Path to the directory where the file is to be stored.
        Returns:
        the path to the directory where the file is to be stored.
      • canBeAccessedBy

        public boolean canBeAccessedBy​(User user)
        Description copied from interface: Securable
        Checks the given user can access this resource.
        Specified by:
        canBeAccessedBy in interface Securable
        Parameters:
        user - a user in Silverpeas.
        Returns:
        true if the user can access the data managed by this instance, false otherwise.
      • canBeModifiedBy

        public boolean canBeModifiedBy​(User user)
        Description copied from interface: Securable
        Checks the given user can modify this resource. By default, if the user can access this securable resource, then it can also modify it.
        Specified by:
        canBeModifiedBy in interface Securable
        Parameters:
        user - a user in Silverpeas.
        Returns:
        true if the user can modify the data managed by this instance, false otherwise.