Class UpdateSettings

java.lang.Object
com.saperion.ngc.model.document.UpdateSettings

public class UpdateSettings extends Object
Contains the settings needed to update a document.
  • Constructor Details

    • UpdateSettings

      public UpdateSettings()
  • Method Details

    • setCheckin

      public UpdateSettings setCheckin(boolean checkin)
      Parameters:
      checkin - whether to checkin the document or not (default = false)
      Returns:
      current instance
    • setLookup

      public UpdateSettings setLookup(boolean lookup)
      Parameters:
      lookup - whether the item to update is a lookup-item (default = false)
      Returns:
      current instance
    • setComment

      public UpdateSettings setComment(String comment)
      Parameters:
      comment - revision comment (default = "")
      Returns:
      current instance
    • setSelectedImage

      public UpdateSettings setSelectedImage(int selectedImage)
      Parameters:
      selectedImage - selected image for thumbnail-control (default = -1)
      Returns:
      current instance
    • setAcls

      public UpdateSettings setAcls(Set<String> acls)
      Parameters:
      acls - ACLs to add to the document (default = null)
      Returns:
      current instance
    • setSaveAction

      public UpdateSettings setSaveAction(com.saperion.ngc.iform.xml.SaveActionType saveAction)
      Parameters:
      saveAction - action to perform after saving
      Returns:
      current instance
    • isCheckin

      public boolean isCheckin()
      Returns:
      whether to checkin the document or not
    • isLookup

      public boolean isLookup()
      Returns:
      whether the item to update is a lookup item or not
    • getComment

      public String getComment()
      Returns:
      the revision comment
    • getSelectedImage

      public int getSelectedImage()
      Returns:
      selected image property for thumbnail-control
    • getAcls

      public Set<String> getAcls()
      Returns:
      ACLs to add to the document
    • getSaveAction

      public com.saperion.ngc.iform.xml.SaveActionType getSaveAction()
      Returns:
      action to perform after saving
    • setVariables

      public UpdateSettings setVariables(Map<String,DocumentVariable> variables)
      Parameters:
      variables - variables to add to document
      Returns:
      current instance
    • getVariables

      public Map<String,DocumentVariable> getVariables()
      Returns:
      variables to add to document
    • isDeleted

      public boolean isDeleted()
      Returns:
      if the document that is updated is deleted
    • setDeleted

      public void setDeleted(boolean deleted)
      Parameters:
      deleted - if the document that is updates is deleted or not
    • isCommentDialogEnabled

      public boolean isCommentDialogEnabled()
      Returns:
      if the comment dialog is enabled or disabled
    • setCommentDialogEnabled

      public UpdateSettings setCommentDialogEnabled(boolean commentDialogEnabled)
      Parameters:
      commentDialogEnabled - whether the comment dialog is enabled or not
      Returns:
      current instance
    • setDefaultComment

      public UpdateSettings setDefaultComment(String defaultComment)
      Parameters:
      defaultComment - default comment for the new revision
      Returns:
      current instance
    • getDefaultComment

      public String getDefaultComment()
      Returns:
      default comment for new revision
    • getEditEvent

      public EditSelectedEvent getEditEvent()
      Returns the edit-event that started the edit-action that uses this UpdateSettings. The event can be used to repeat the last edit-action when a save-and-button was pressed.
      Returns:
      the last edit-event or null of not set
    • setEditEvent

      public UpdateSettings setEditEvent(EditSelectedEvent editEvent)
      Sets the edit-event that started the edit-action that uses this UpdateSettings. The event can be used to repeat the last edit-action when a save-and-button was pressed.
      Parameters:
      editEvent - the last edit-event
      Returns:
      current instance