Interface SaRMIServerCommand

All Superinterfaces:
Remote

public interface SaRMIServerCommand extends Remote
Server-side Command interface representing the functionality of the core server.
  • Method Details

    • isRevisionEnabled

      boolean isRevisionEnabled(int token, String ddcName) throws RemoteException
      Gets the information whether the provided ddc table contains the fields required for revisions.
      Parameters:
      token - user token number
      ddcName - table/jcr workspace name
      Returns:
      true, if the revision fields are present. False otherwise.
      Throws:
      RemoteException - Remote exception
    • logon

      com.saperion.connector.authentication.Session logon(com.lexmark.saperion.remote.common.authentication.Credentials credentials) throws RemoteException, com.lexmark.saperion.exceptions.EcmException
      Logon with the passed credentials.
      Parameters:
      credentials - credentials which should be used for logon
      Returns:
      the session information about the created one
      Throws:
      RemoteException - error on user login
      com.lexmark.saperion.exceptions.EcmException
    • logon

      com.saperion.connector.authentication.Session logon(com.lexmark.saperion.remote.common.authentication.Credentials credentials, com.saperion.connector.authentication.SessionInfo sessionInfo) throws RemoteException, com.lexmark.saperion.exceptions.EcmException
      Logon with the passed credentials and associate the given session information.
      Parameters:
      credentials - The credentials which should be used for logon
      sessionInfo - The session information
      Returns:
      An instance of Session
      Throws:
      RemoteException
      com.lexmark.saperion.exceptions.EcmException
    • listActiveSessions

      List<com.saperion.connector.authentication.Session> listActiveSessions(int token) throws RemoteException
      List the active sessions of the user identified by given token.
      Parameters:
      token -
      Returns:
      List of Session
      Throws:
      RemoteException
    • closeSession

      boolean closeSession(int token, com.saperion.connector.authentication.Session session) throws RemoteException
      Close the given Session of the user identified by the given token
      Parameters:
      token -
      session -
      Returns:
      true if logged off successfully, false otherwise
      Throws:
      RemoteException
    • getUserIdsForQuery

      int[] getUserIdsForQuery(int token) throws RemoteException
      Read the userids.
      Parameters:
      token - User token
      Returns:
      User ids
      Throws:
      RemoteException - SaRMICommandException
    • logoff

      boolean logoff(int token) throws RemoteException
      Logoff the user from the server instance.
      Parameters:
      token - User token
      Returns:
      True, if done.
      Throws:
      RemoteException - error on user logoff
    • setLocale

      void setLocale(int token, Locale local) throws RemoteException
      Set the locale for localization.
      Parameters:
      token - User token
      local - Locale
      Throws:
      RemoteException - Exception
    • getMembers

      WorkflowMember getMembers(int token) throws RemoteException
      Reads the member.
      Parameters:
      token - User token
      Returns:
      Member tree
      Throws:
      RemoteException - Remote exception
    • getMember

      WorkflowMember getMember(int token, WorkflowMember member, int depth, String filter) throws RemoteException
      Reads direct workflow member.
      Parameters:
      token - User token
      member - workflow member, witch direct children will be returned
      depth - depth of the returned children.
      filter - filter string
      Returns:
      Member tree
      Throws:
      RemoteException - Remote exception
    • loadDDCNames

      String[] loadDDCNames(int token) throws RemoteException
      Retrieves the avaiable DDC names.
      Parameters:
      token - User token
      Returns:
      Array of DDC names
      Throws:
      RemoteException - Error on the saperion system
    • loadFolderDDCNames

      String[] loadFolderDDCNames(int token) throws RemoteException
      Retrieves the avaiable folder DDC names.
      Parameters:
      token - User token
      Returns:
      Array of folder DDC names
      Throws:
      RemoteException - Error on the saperion system
    • loadWorkflowDDCName

      String loadWorkflowDDCName() throws RemoteException
      Retrieves the workflow DDC name.
      Returns:
      workflow DDC names
      Throws:
      RemoteException - Error on the saperion system
    • getFieldDescriptions

      SaFieldDescription[] getFieldDescriptions(int token, String ddcName) throws RemoteException
      Reads the field descriptions for a given DDC.
      Parameters:
      token - User token
      ddcName - DDC name
      Returns:
      Array of field description objects
      Throws:
      RemoteException - Error on the saperion system
    • getUserSetting

      SaUserSetting getUserSetting(int token, String key) throws RemoteException
      Reads the user-specific settings for the given key.
      Parameters:
      token - User token
      key - Dot-delimited key
      Returns:
      SaUserSetting
      Throws:
      RemoteException - Error on the saperion system
    • setUserSetting

      void setUserSetting(int token, SaUserSetting value) throws RemoteException
      Persists user-specific settings to the saperion backend.
      Parameters:
      token - User token
      value - user setting object
      Throws:
      RemoteException - Error on the saperion system
    • getSetting

      Setting getSetting(int token, String name, String section, boolean isLong) throws RemoteException
      Reads the setting with the specified name and section.
      Parameters:
      token - User token
      name - the setting's name
      section - the setting's section
      isLong - whether this is a setting with a long (>2KB) value or not
      Returns:
      the setting or null if no setting with the given key and section was found
      Throws:
      RemoteException - Error when retrieving the setting
    • searchSettings

      SettingSearchResult searchSettings(int token, SettingSearchInfo searchInfo) throws RemoteException
      Searches for settings.
      Parameters:
      token - User token
      searchInfo - SettingSearchInfo containing information about what to search
      Returns:
      a SettingSearchResult
      Throws:
      RemoteException - system error when searching
    • setSetting

      void setSetting(int token, Setting setting) throws RemoteException
      Persists the setting in the database.
      Parameters:
      token - User token
      setting - the setting to persist
      Throws:
      RemoteException - Error when persisting the setting
    • deleteSetting

      boolean deleteSetting(int token, String name, String section, boolean isLong) throws RemoteException
      Deletes a setting in the database.
      Parameters:
      token - User token
      name - the name of the setting to delete
      section - the section of the setting to delete
      isLong - whether this is a setting with a long (>2KB) value or not
      Returns:
      true if setting was deleted, false if there was no such setting
      Throws:
      RemoteException - Error when deleting the setting
    • getAllACLs

      @Deprecated List<String> getAllACLs(int token) throws RemoteException
      Deprecated.
      use getAcls(int) instead
      Reads all existing ACL names.
      Parameters:
      token - User token
      Returns:
      List of ACL names
      Throws:
      RemoteException - Remote exception
    • getAcls

      List<SaAcl> getAcls(int token) throws RemoteException
      Reads all existing Acls.
      Parameters:
      token - User token
      Returns:
      List of ACLs
      Throws:
      RemoteException - Remote exception
    • readDocumentFirst

      com.saperion.jni.SaJNIReadBuffer readDocumentFirst(int token, String hdoc, boolean currentRevision, int element) throws RemoteException
      Opens an existing document with the given hdoc and returns a document handle for the specified element (= sub-document) as well as the buffer containing the content data of the element. If this was the last block, the document is automatically closed.
      Parameters:
      token - User token
      hdoc - Document HDOC
      currentRevision - flag indicating that the current revision of the document should be retrieved by resolving hdoc
      element - Element number, starting with 1
      Returns:
      The document handle and the buffer with the content
      Throws:
      RemoteException - Error on the saperion system
    • readDocumentFirst

      com.saperion.jni.SaJNIReadBuffer readDocumentFirst(int token, String hdoc, boolean currentRevision, int element, boolean withAnnotations) throws RemoteException
      Opens an existing document with the given hdoc and returns a document handle for the specified element (= sub-document) as well as the buffer containing the content data of the element. If this was the last block, the document is automatically closed.
      Parameters:
      token - User token
      hdoc - Document HDOC
      currentRevision - flag indicating that the current revision of the document should be retrieved by resolving hdoc
      element - Element number, starting with 1
      withAnnotations - if true, annotations will be saved on the document
      Returns:
      The document handle and the buffer with the content
      Throws:
      RemoteException - Error on the saperion system
    • readDocumentMetadata

      SaPropertyValue[] readDocumentMetadata(int token, String documentHDOC, String ddcName, String[] fields) throws RemoteException, SaSystemException
      Reads the metadata of the document with the given ID.
      Parameters:
      token - Token
      documentHDOC - The ID of the document (SYSROWID)
      ddcName - The name of the database definition
      fields - Fieldnames to be read. If empty or null, all fields will be read.
      Returns:
      The Metadata of the document represented as an array of SaPropertyValue instances.
      Throws:
      RemoteException - RemoteException
      SaSystemException
    • getFulltext

      String getFulltext(int token, String ddcName, String sysRowId, String hdoc, String fieldName, long length) throws RemoteException
      Reads the fulltext information for the given document with the given SYSROWID in the given DDC.
      Parameters:
      token - Token
      ddcName - DDC name of the document
      sysRowId - SYSROWID of the document. Can be null if hdoc is set. If both hdoc and sysRowId are set, hdoc will be used.
      hdoc - HDOC of the document. Can be null if sysRowId is set. If both hdoc and sysRowId are set, hdoc will be used.
      fieldName - name of the fulltext field to retrieve content from. If not set, the first fulltext field of the DDC will be used
      length - maximum length of content to retrieve. If -1, the complete content will be returned.
      Returns:
      Content of the fulltext for this document
      Throws:
      RemoteException - RemoteException
    • getThumbnail

      byte[] getThumbnail(int token, String hDoc, int widthX, int widthY, boolean color) throws RemoteException
      Reads the thumbnail of the given document.
      Parameters:
      token - Token
      hDoc - HDoc for the document.
      widthX - Width X
      widthY - Width Y
      color - True for colored
      Returns:
      Thumbnail BMP as byte array
      Throws:
      RemoteException - RemoteException
    • readDocumentNext

      com.saperion.jni.SaJNIReadBuffer readDocumentNext(int token, com.saperion.jni.SaJNIDocHandle handle) throws RemoteException
      Reads the next bytes from the open document, decribed in the handle. If this was the last block, the document is automatically closed.
      Parameters:
      token - Usertoken
      handle - Document handle for a document, opend by readDocumentFirst
      Returns:
      The document handle and the buffer with the content
      Throws:
      RemoteException - Error on the saperion system
    • readVersionMetadata

      SaVersionData readVersionMetadata(int token, String versionID) throws RemoteException
      Reads the version metadata of the document with the given ID.
      Parameters:
      token - User token
      versionID - Version HDOC
      Returns:
      Document revision data
      Throws:
      RemoteException - Remote exception
    • readVersionMetadata

      SaVersionData readVersionMetadata(int token, String versionID, boolean resolveLinks) throws RemoteException
      Reads the version metadata of the document with the given ID.
      Parameters:
      token - User token
      resolveLinks - If false will not resolve the link and show the metadata associated with the link itself.
      versionID - Version HDOC
      Returns:
      Document revision data
      Throws:
      RemoteException - Remote exception
    • restoreVersion

      SaSaveInfo restoreVersion(int token, String versionID) throws RemoteException
      Restores the given version to the actual version.
      Parameters:
      token - User token
      versionID - Version HDOC
      Returns:
      Document save info
      Throws:
      RemoteException - Remote exception
    • closeDocument

      void closeDocument(int token, com.saperion.jni.SaJNIDocHandle handle) throws RemoteException
      Manually closing of a open document.
      Parameters:
      token - Usertoken
      handle - Document handle for a document, opend by readDocumentFirst
      Throws:
      RemoteException - Error on the saperion system
    • deleteDocument

      SaSaveInfo deleteDocument(int token, int mode, String hdoc) throws RemoteException
      Delete a document.
      Parameters:
      token - Usertoken
      mode - Delete mode may be set to the following values:
    • SaConstant.JNI_DELETECONTENT_MODE_DBSIMPLE = 0 Set status to 65002
    • SaConstant.JNI_DELETECONTENT_MODE_DBCOMPLETE = 1 - remove from DB
    • SaConstant.JNI_DELETECONTENT_MODE_PURGEDOCUMENT = 2 -Final delete
    • SaConstant.DELETEMODE = "deletemode" -Deletemode entry in archief.ini;
    • hdoc - Document HDOC
      Returns:
      SaSaveInfo or null
      Throws:
      RemoteException - Error on the saperion system
    • cacheDocument

      SaSaveInfo cacheDocument(int token, boolean isNew, int commitMode, String versionComment, String xhDoc, String ddcName, String acls) throws RemoteException
      Caches the current document to the backend.
      Parameters:
      token - Usertoken
      isNew - Is a new document
      commitMode - Commit mode
      versionComment - Version comment string
      ddcName - DDC name
      acls - ACL name string, if null it will be ignored, to delete existing ACLs set an empty string
      xhDoc - the document's hdoc
      Returns:
      Node information object
      Throws:
      RemoteException - RMI Exception
    • createDocument

      SaSaveInfo createDocument(int token, String ddcName, List<SaPropertyValue> values) throws RemoteException
      Caches a new document with the given parameters.
      Parameters:
      token - User token (an int variable to authentificate an user)
      ddcName - Node database table name
      values - List of all values
      Returns:
      Node information object
      Throws:
      RemoteException - RMI Exception
    • createLink

      SaSaveInfo createLink(int token, LinkInfo link) throws RemoteException
      Creates a SAPERION Link into one Archive for an existing Document.
      Parameters:
      token - User token (an int variable to authentificate an user)
      link - Link for the existing Document
      Returns:
      Save Info after the Link was created
      Throws:
      RemoteException - RMI Exception
    • saveDocument

      SaSaveInfo saveDocument(int token, String nodeHdoc, String ddcName, List<SaPropertyValue> values) throws RemoteException
      Saves the document parameters to the document.
      Parameters:
      token - Usertoken
      nodeHdoc - Node HDOC
      ddcName - Database table name
      values - List of all values
      Returns:
      written node informations
      Throws:
      RemoteException - RMI Exception
    • saveDocument

      SaSaveInfo saveDocument(int token, String nodeHdoc, String ddcName, List<SaPropertyValue> values, boolean resolveLinks) throws RemoteException
      Saves the document parameters to the document.
      Parameters:
      token - Usertoken
      nodeHdoc - Node HDOC
      ddcName - Database table name
      values - List of all values
      resolveLinks - Resolve links
      Returns:
      written node informations
      Throws:
      RemoteException - RMI Exception
    • storeDocument

      SaSaveInfo storeDocument(int token, boolean isNew, int commitMode, String versionComment, String ddcName, String acls) throws RemoteException
      Stores the actual document to the backend.
      Parameters:
      token - Usertoken
      isNew - Is a new document
      commitMode - Commit mode
      versionComment - Version comment string
      ddcName - DDC name
      acls - ACL name string, if null it will be ignored, to delete existing ACLs set an empty string
      Returns:
      Node information object
      Throws:
      RemoteException - RMI Exception
    • storeDocument

      SaSaveInfo storeDocument(int token, boolean isNew, int commitMode, String versionComment, String ddcName, String acls, boolean checkin) throws RemoteException
      Stores the actual document to the backend.
      Parameters:
      token - Usertoken
      isNew - Is a new document
      commitMode - Commit mode
      versionComment - Version comment string
      ddcName - DDC name
      acls - ACL name string, if null it will be ignored, to delete existing ACLs set an empty string
      checkin - Checkin document (only valid for update)
      Returns:
      Node information object
      Throws:
      RemoteException - RMI Exception
    • discardDocument

      void discardDocument(int token) throws RemoteException
      Discards the document identified by the tokens handle. Cleans up temporary document resources and open handles.
      Parameters:
      token - Usertoken
      Throws:
      RemoteException - RMI Exception
    • checkoutDocument

      void checkoutDocument(int token, String documentHdoc) throws RemoteException
      Checkout the document with the given HDOC. The document must be stored.
      Parameters:
      token - User token
      documentHdoc - Document HDOC
      Throws:
      RemoteException - RMI exception
    • checkoutDocument

      void checkoutDocument(int token, String documentHdoc, boolean withCloudShare, int[] shareBaseDocIds) throws RemoteException
      Checkout the document with filesystem/ShareBase for the given HDOC. The document must be stored. Checkout a open document
      Parameters:
      token - User token
      documentHdoc - * Document HDOC
      withCloudShare - true if open document is checked out with ShareBase else false
      shareBaseDocIds - Array of sharebase doc ids for open checkout docs
      Throws:
      RemoteException - RMI exception
    • discardCheckout

      void discardCheckout(int token, String documentHdoc) throws RemoteException
      Discard a checked out document.
      Parameters:
      token - User token
      documentHdoc - Document HDOC
      Throws:
      RemoteException - RMI exception
    • releaseDocument

      void releaseDocument(int token, String documentHdoc, String comment) throws RemoteException
      Release the document with the given HDOC. The document must be stored. ACLs and SVRELEASE variable are set.
      Parameters:
      token - User token
      documentHdoc - Document HDOC
      comment - the revision comment
      Throws:
      RemoteException - RMI exception
    • writeDocument

      long writeDocument(int token, String filename, byte[] buffer, boolean isLast, int element) throws RemoteException
      Writes given binary content to an existing document object.
      Parameters:
      token - User token
      filename - File name of content, set on first invocation
      buffer - Buffer containing content data
      isLast - True if this is the last block of data
      element - Element number or -1 for automatic
      Returns:
      Actual element count
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • writeDocument

      long writeDocument(int token, String filename, byte[] buffer, boolean isLast, int element, boolean doStreaming) throws RemoteException
      Writes given binary content to an existing document object.
      Parameters:
      token - User token
      filename - File name of content, set on first invocation
      buffer - Buffer containing content data
      isLast - True if this is the last block of data
      doStreaming - True if streaming option of content data is activated.
      element - Element number or -1 for automatic
      Returns:
      Actual element count
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • writeDocument

      long writeDocument(int token, SerializableStream stream) throws RemoteException
      Write document.
      Parameters:
      token - the User token
      stream - the stream to write
      Returns:
      the Actual element count
      Throws:
      RemoteException - the remote exception
    • setElementMark

      void setElementMark(int token, int element) throws RemoteException
      Mark the content element.
      Parameters:
      token - User token
      element - Element number to mark
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • removeElement

      void removeElement(int token, int element) throws RemoteException
      Removes a existing content element.
      Parameters:
      token - User token
      element - Element number
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • removeElement

      void removeElement(int token, Integer[] elements) throws RemoteException
      Removes a series of existing content elements.
      Parameters:
      token - User token
      elements - Array of element number
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • clearContent

      void clearContent(int token) throws RemoteException
      Clears all content of the opened document.
      Parameters:
      token - Usertoken
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • lockNode

      boolean lockNode(int token, String sysRowId, String ddcName, int lockType, boolean sessionScoped) throws RemoteException
      Locks a node.
      Parameters:
      token - Usertoken
      sysRowId - SysRowId
      ddcName - DDC name
      lockType - locking mode can be one of the following constants:
    • SaConstant.LOCKING_LOCKTYPE_DEFAULT = 0;
    • SaConstant.LOCKING_LOCKTYPE_JSRLOCK = 1;
    • SaConstant.LOCKING_LOCKTYPE_JSRCHECKOUT = 2;
    • sessionScoped - True, if session scoped
      Returns:
      True, if ok
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • unlockNode

      boolean unlockNode(int token, String sysRowId, String ddcName) throws RemoteException
      Unlocks a node.
      Parameters:
      token - Usertoken
      sysRowId - SysRowId
      ddcName - DDC name
      Returns:
      True, if ok
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • getLockInfo

      SaLockInfo getLockInfo(int token, String sysRowId) throws RemoteException
      Gets the lock info for a given node.
      Parameters:
      token - Usertoken
      sysRowId - SysRowId
      Returns:
      Lockinfo
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • getNodeAccessData

      com.saperion.jni.SaJNIDocAccessData getNodeAccessData(int token, String hdoc) throws RemoteException
      Opens the document identified by hdoc and returns an object containing all access right data information for the session user.
      Parameters:
      token - User token
      hdoc - Document HDOC
      Returns:
      SaJNIDocAccessData Document access data for session user
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • startTransaction

      void startTransaction(int token) throws RemoteException
      Starts a transaction in the backend system.
      Parameters:
      token - Usertoken
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • finishTransaction

      void finishTransaction(int token, boolean commit) throws RemoteException
      Finish the transaction in the backend system.
      Parameters:
      token - Usertoken
      commit - True, if commit this transaction, false to rollback
      Throws:
      RemoteException - Wrapped SaJNIException and SaRMIException
    • getIdsFromQuery

      List<String> getIdsFromQuery(int token, String query, boolean isSQL) throws RemoteException
      Executes a HQL query and returns the results as a string list.
      Parameters:
      token - User token
      query - HQL query
      isSQL - isSQL
      Returns:
      List string result list
      Throws:
      RemoteException - Remote exception
    • getStringQueryResult

      List<SaDocumentInfo> getStringQueryResult(int token, SaQueryInfo queryInfo) throws RemoteException, SaSystemException
      Executes a given HQL string and returns the results as list.
      Parameters:
      token - User token
      queryInfo - HQL query info
      Returns:
      Result list
      Throws:
      RemoteException - Remote exception
      SaSystemException
    • getVersionList

      List<String> getVersionList(int token, String ddcName, String sysrowID) throws RemoteException
      Reads the versionlist for the given document.
      Parameters:
      token - User token
      ddcName - DDC name
      sysrowID - SYSROWID
      Returns:
      List of HDOC's
      Throws:
      RemoteException - Remote exception
    • getACLNames

      String getACLNames(int token, String hDoc) throws RemoteException
      Reads the ACL's for the given document.
      Parameters:
      token - User token
      hDoc - Document HDOC
      Returns:
      ACL name string
      Throws:
      RemoteException - RemoteException
    • setACLName

      SaSaveInfo setACLName(int token, String ddcname, String hDoc, String acl, int commitMode, String versionComment) throws RemoteException
      Sets the given ACL to the node.
      Parameters:
      token - User token
      ddcname - implemented ddc in saperion
      hDoc - Document HDOC
      acl - ACL name string
      commitMode - Commit mode
      versionComment - Version comment string
      Returns:
      save info object
      Throws:
      RemoteException - RemoteException
    • getACLRights

      SaACLRights getACLRights(int token, String[] acls) throws RemoteException
      Reads the rights for the given ACL's.
      Parameters:
      token - User token
      acls - Array of ACL's
      Returns:
      ACL rights
      Throws:
      RemoteException - Remote exception
    • getInvolvedUsers

      List<String> getInvolvedUsers(int token, String hDoc) throws RemoteException
      Reads all users involved in the set of ACL's.
      Parameters:
      token - User token
      hDoc - Document HDOC
      Returns:
      List of user names
      Throws:
      RemoteException - RemoteException
    • resolveLatestHdoc

      String resolveLatestHdoc(int token, String oldHdoc) throws RemoteException
      Resolves the hdoc of the latest version of the document identified by the given hdoc.
      Parameters:
      token - User token
      oldHdoc - old document HDOC
      Returns:
      the hdoc of the latest version of the document identified by the given hdoc.
      Throws:
      RemoteException - if an remote error occurs.
    • getHDocForSysRowId

      String getHDocForSysRowId(int token, String sysRowId, String ddcName) throws RemoteException
      Searchs the HDOC for the given SysRowId.
      Parameters:
      token - User token
      sysRowId - SysRowId
      ddcName - DDC name
      Returns:
      Resultset for HDOC's
      Throws:
      RemoteException - Remoteexception
    • isAlive

      boolean isAlive(int token) throws RemoteException
      Checks, if the token has minimum lifetime before timeout.
      Parameters:
      token - Usertoken
      Returns:
      True, if the token is alive
      Throws:
      RemoteException - Remote exception
    • getTaskList

      List<TaskInfo> getTaskList(int token, int[] ids, String filter, Map<String,Object> parameter) throws RemoteException
      Reads the task for this user.
      Parameters:
      token - user token
      ids - Box ID's
      filter - HQL filter. Optional WHERE condition that might be added to the original query.
      In order to add the pagination functionality like setMaxResults() and/or setFirstResult(), enhance filter with the following statements:
      filter_stmt;MAXRESULTS=x ;FIRSTRESULT=y.
      ;MAXRESULTS=x - x means the limitation of the result set output.
      ;FIRSTRESULT=y - y means setting the result set cursor to the y-position.
      Adding pagination is optional feature that can be used without filter statement as well. In other words filter might constist of ;MAXRESULTS=x ;FIRSTRESULT=y string only.

      Examples:
      1. LASTUSER ='Bolt';MAXRESULTS=50 ;FIRSTRESULT=1 - hql query's where condition is enhanced with restriction LASTUSER ='Bolt' and the pagination functionality setMaxResults() and setFirstResult() is used;

      2. ;MAXRESULTS=50 - only setMaxResult() will be used.

      using ; ist important for applying pagination.
      parameter - Filter parameter
      Returns:
      List of TaskInfo objects
      Throws:
      RemoteException - RemoteException
    • countTasks

      long countTasks(int token, int[] ids, String filter, Map<String,Object> filterParams) throws RemoteException, SaSystemException, SaAuthenticationException
      Counts the tasks that are contained in the specified inbox(es). Unlike getBoxCount(int, int, BoxCountType, Map), this method allows to define a custom filter. It uses the same queries than getTaskList(int, int[], String, Map).
      Parameters:
      token - user-token
      ids - IDs of the inboxes to count tasks in
      filter - optional filter-string in HQL that will be added to the WHERE clause
      filterParams -
      Returns:
      Throws:
      RemoteException - RMI exception when invoking this call
      SaSystemException - system error when counting workflow tasks
      SaAuthenticationException - not authorized or not logged on
    • getTaskAuditList

      List<TaskAuditInfo> getTaskAuditList(int token, int[] ids, String filter, Map<String,Object> parameter) throws RemoteException
      Reads the task for this user.
      Parameters:
      token - user token
      ids - Box ID's
      filter - HQL filter. Optional WHERE condition that will be added to the original query.
      In order to add the pagination functionality like setMaxResults() and/or setFirstResult(), add the following statements to the filter:
      filter_stmt;MAXRESULTS=x ;FIRSTRESULT=y.
      ;MAXRESULTS=x - x means the limitation of the result set output.
      ;FIRSTRESULT=y - y means setting the result set cursor to the y-position.
      Adding pagination is optional feature that can be used without filter statement as well. In other words filter might consist of ;MAXRESULTS=x ;FIRSTRESULT=y string only.

      Examples:
      1. LASTUSER ='Bolt';MAXRESULTS=50 ;FIRSTRESULT=1 - hql query's where condition is enhanced with restriction LASTUSER ='Bolt' and the pagination functionality setMaxResults() and setFirstResult() is used;

      2. ;MAXRESULTS=50 - only setMaxResult() will be used.

      using ; ist important for applying pagination.
      parameter - Filter parameter
      Returns:
      List of TaskAuditInfo objects
      Throws:
      RemoteException - RemoteException
    • getTask

      TaskInfo getTask(int token, String taskID) throws RemoteException
      Reads the task info for the given ID.
      Parameters:
      token - user token
      taskID - Task ID
      Returns:
      Task info
      Throws:
      RemoteException - RemoteException
    • getParentTask

      TaskInfo getParentTask(int token, String taskID) throws RemoteException
      Reads the parent task info for the given ID.
      Parameters:
      token - user token
      taskID - Task ID
      Returns:
      Task info
      Throws:
      RemoteException - RemoteException
    • getCommandInfos

      Collection<CommandInfo> getCommandInfos(int token, String docUID) throws RemoteException
      Reads all possible transitions for this task.
      Parameters:
      token - user token
      docUID - Document UID
      Returns:
      Command list
      Throws:
      RemoteException - RemoteException
    • getCommandInfos

      Collection<CommandInfo> getCommandInfos(int token, String docUID, boolean transitionsOnly) throws RemoteException
      Reads all possible transitions for this task.
      Parameters:
      token - user token
      docUID - Document UID
      transitionsOnly - if true, only transition commands will be returned
      Returns:
      Command list
      Throws:
      RemoteException - RemoteException
    • getBoxDefinitions

      List<BoxDefinition> getBoxDefinitions(int token) throws RemoteException
      Reads the box definitions.
      Parameters:
      token - user token
      Returns:
      Box definitions
      Throws:
      RemoteException - RemoteException
    • getBoxCounts

      HashMap<Integer,BoxCount> getBoxCounts(int token, Set<Integer> boxId, BoxCountType type, Map<String,Object> parameters) throws RemoteException
      Returns the number of all elements and of all unread elements of the inboxes identified by the given ids.
      Parameters:
      token - user token
      boxId - the workflow box id
      type - type of tasks to search for
      parameters - parameters needed for query
      Returns:
      number of all elements and of all unread elements
      Throws:
      RemoteException - if an error occurs.
    • getBoxCount

      BoxCount getBoxCount(int token, int boxId, BoxCountType type, Map<String,Object> parameters) throws RemoteException
      Returns the number of all elements and of all unread elements of the inbox identified by the given id.
      Parameters:
      token - user token
      boxId - the workflow box id
      type - type of tasks to search for
      parameters - parameters needed for query
      Returns:
      number of all elements and of all unread elements
      Throws:
      RemoteException - if an error occurs.
    • executeCommand

      String executeCommand(int token, ContextInfo contextInfo) throws RemoteException
      Performs the given command. The parameters must fit to the given parameter. Unneeded parameters can be set to null.
      Parameters:
      token - user token
      contextInfo - Context info
      Returns:
      New TaskID
      Throws:
      RemoteException - RemoteException
    • getCommentInfos

      List<CommentInfo> getCommentInfos(int token, String taskUID) throws RemoteException
      Reads the comments for the given task.
      Parameters:
      token - user token
      taskUID - Task UID
      Returns:
      List of comments
      Throws:
      RemoteException - RemoteException
    • getHistoryInfos

      List<HistoryInfo> getHistoryInfos(int token, String taskUID) throws RemoteException
      Reads the history for the given task.
      Parameters:
      token - user token
      taskUID - Task UID
      Returns:
      History list
      Throws:
      RemoteException - RemoteException
    • getCompleteHistoryInfos

      List<List<HistoryInfo>> getCompleteHistoryInfos(int token, String docUID) throws RemoteException
      Reads the histories and comments for the given document.
      Parameters:
      token - user token
      docUID - document UID
      Returns:
      CompleteHistoryInfo
      Throws:
      RemoteException - RemoteException
    • getWorkflowDefinitions

      List<String> getWorkflowDefinitions(int token) throws RemoteException
      Reads all available workflow definitions.
      Parameters:
      token - user token
      Returns:
      Workflowdefinition list
      Throws:
      RemoteException - RemoteException
    • getWorkflowDefinitions

      List<ProcessDefinitionDescriptor> getWorkflowDefinitions(String ddcName, int token) throws RemoteException, com.lexmark.saperion.exceptions.system.BackendSystemException
      Returns the workflow definitions that are allowed to be used for documents contained in the specified DDC. If no restrictions are configured, all workflow definitions will be returned.
      Parameters:
      ddcName - name of the DDC
      token - user token
      Returns:
      Workflowdefinition list
      Throws:
      RemoteException - RemoteException
      com.lexmark.saperion.exceptions.system.BackendSystemException
    • addComment

      void addComment(int token, String comment, String taskUID, int level) throws RemoteException
      Parameters:
      token - user token
      comment - Comment
      taskUID - Task UID
      level - Level
      Throws:
      RemoteException - RemoteException
    • addHistory

      void addHistory(int token, String description, String taskUID) throws RemoteException
      Parameters:
      token - user token
      description - Comment
      taskUID - Task UID
      Throws:
      RemoteException - RemoteException
    • getSubstitute

      String getSubstitute(int token) throws RemoteException
      Get the substitute for the logged on user.
      Parameters:
      token - user token
      Returns:
      Substitute name
      Throws:
      RemoteException - RemoteException
    • setSubstitute

      void setSubstitute(int token, String name) throws RemoteException
      Set the substitute for the logged on user.
      Parameters:
      token - user token
      name - Substitute name
      Throws:
      RemoteException - RemoteException
    • getOutOfOffice

      boolean getOutOfOffice(int token) throws RemoteException
      Get the out of office status for the logged on user.
      Parameters:
      token - user token
      Returns:
      is OutOfOffice
      Throws:
      RemoteException - RemoteException
    • setOutOfOffice

      void setOutOfOffice(int token, boolean isOutOfOffice) throws RemoteException
      Set the out of office status for the logged on user.
      Parameters:
      token - user token
      isOutOfOffice - True, if is OutOfOffice
      Throws:
      RemoteException - RemoteException
    • getUsers

      List<String> getUsers(int token, String filter) throws RemoteException
      Reads a list of filtered users.
      Parameters:
      token - user token
      filter - Filter
      Returns:
      List of users
      Throws:
      RemoteException - RemoteException
    • getAnnotations

      String getAnnotations(int token, int indexOfContentElement, String hDoc, boolean currentRevision) throws RemoteException
      Reads the annotations from the given document.
      Parameters:
      token - user token
      indexOfContentElement - the index of the content element to access
      hDoc - document HDOC
      currentRevision - true to get current revision
      Returns:
      Annotation string
      Throws:
      RemoteException - RemoteException
    • setAnnotations

      void setAnnotations(int token, String hDoc, int indexOfContentElement, String annotations) throws RemoteException
      Sets the given annotations to the document. This method creates a new revision.
      Parameters:
      token - user token
      hDoc - Document HDOC
      indexOfContentElement - the index of the content element to access
      annotations - Annotation string
      Throws:
      RemoteException - RemoteException
    • startSQLTransaction

      void startSQLTransaction(int token, String ddcName) throws RemoteException
      Start SQL transaction.
      Parameters:
      token - User token
      ddcName - the name of the ddc
      Throws:
      RemoteException - RemoteException
    • finishSQLTransaction

      void finishSQLTransaction(int token, boolean commit, String ddcName) throws RemoteException
      Finish SQL transaction.
      Parameters:
      token - User token
      ddcName - the ddc name
      commit - True, if commit, else rollback
      Throws:
      RemoteException - RemoteException
    • getFolderChildren

      List<SaDocumentInfo> getFolderChildren(int token, String folderTableDDC, String folderId, int depth, SaQueryInfo filter, int allowedMaxNrOfChildFolders) throws RemoteException
      Returns a cursor with the children of the given node. The function accepts a depth parameter. In case of a depth greater than one, the returned nodes are ordered in a depth-first order, and the caller must detect parent-child relationship with the appropriate fields (SysParentID, SysRowID). Note that searching with a depth greater than one is not a fast operation. It is recommended to use depth = 1 and only load further levels on demand if required. The allowedMaxNrOfChildFolders parameter is used to restrict the absolute number of hits loaded from the database. It is intended to be used to protect the system from overload problems caused by very large query-results. The depth-filtering is done after the query has returned from the database. So keep in mind that children found on deeper levels than specified in the depth-parameter are relevant for the total number of children found.
      The default value for allowedMaxNrOfChildFolders can be configured with the setting rmi.getfolderchildren.maxresults in saperion.properties of JavaCoreServer. When this setting is set to a value > 0, it is not possible to search for an unlimited number of child nodes by passing a value of -1 for this parameter.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      depth - Depth (range: 1..n), if lower than 1 an exception is thrown
      filter - Additional HQL filter criteria
      allowedMaxNrOfChildFolders - allowed maximum number of results
      Returns:
      List of folder information
      Throws:
      RemoteException - RemoteException
    • getFolderParent

      SaDocumentInfo getFolderParent(int token, String folderTableDDC, String folderId) throws RemoteException
      Returns the parent of the given node. Please note that in case of a node to which another node links, the real parent is returned, not the parent of the link.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      Returns:
      Properties of the folder or null, if not found
      Throws:
      RemoteException - RemoteException
    • getFolderFromPath

      List<SaDocumentInfo> getFolderFromPath(int token, String folderTableDDC, String startNodeId, String folderPath, boolean exact) throws RemoteException
      Returns the node(s) which match to the given path. Path names are built using the SysFolderName field of each node. As path separator, the backslash ('\') is used. The path can be searched relative to a given node, to allow for searching within Personal folders and the like. If exact is set to false, the folderPath can contain wildcards (%). Searching with wildcards can be slow depending on the number of entries in the folder-table and the database in use.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      startNodeId - Startnode ID or null/empty if no relative search is required
      folderPath - Search path
      exact - if true, the path will be matched using '='. If false, LIKE will be used.
      Returns:
      Folder list
      Throws:
      RemoteException - RemoteException
    • createFolder

      String createFolder(int token, SaFolderSaveInfo info) throws RemoteException
      Creates a new node below a given node. The parent node can be the root node (empty id).
      Parameters:
      token - user token
      info - Folder save info
      Returns:
      Save info object
      Throws:
      RemoteException - RemoteException
    • updateFolder

      void updateFolder(int token, String folderTableDDC, String folderId, List<SaPropertyValue> values) throws RemoteException
      Updates a given node with the given properties.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      values - Values
      Throws:
      RemoteException - RemoteException
    • searchFolderDocuments

      List<SaDocumentInfo> searchFolderDocuments(int token, String folderTableDDC, String folderId, SaQueryInfo hqlFilter) throws RemoteException
      HQL search extended with additional folder informations and depth.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      hqlFilter - HQL query for document tables. The DDC name must be defined as $DDC$.
      Returns:
      List of documents from each involved DDC's
      Throws:
      RemoteException - RemoteException
    • deleteFolder

      void deleteFolder(int token, String folderTableDDC, String folderId) throws RemoteException
      Deletes a given node. It must not have children or filed document, i.e. the user must delete/remove all these before deleting the node.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      Throws:
      RemoteException - RemoteException
    • copyFolder

      String copyFolder(int token, String folderTableDDC, String folderId, String destinationId, String beforeChild, boolean withDocuments) throws RemoteException
      Copies the given node and all it’s children to the destination. Note that only real children are copied, so links are not followed. Document filings can optionally be copied too, however this is an expensive operation, as each document has to be updated.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      destinationId - Destination folder ID
      beforeChild - Child ID or empty for append
      withDocuments - True, if documents should be copied
      Returns:
      new folder id
      Throws:
      RemoteException - RemoteException
    • moveFolder

      void moveFolder(int token, String folderTableDDC, String folderId, String destinationId, String beforeChild) throws RemoteException
      Moves the given node to a new destination. Document filings are always moved with the node. This is not a quick operation, as path and security information must be updated.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      destinationId - Destination folder ID
      beforeChild - Child ID or empty for append
      Throws:
      RemoteException - RemoteException
    • addToFolder

      void addToFolder(int token, String folderTableDDC, String documentId, String documentDDC, String folderId) throws RemoteException
      Adds the document to a given folder. A document can be filed in multiple folders, but each filing operation must be called separately.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      documentId - Document SysRowId
      documentDDC - Document DDC name
      folderId - Destination folder ID
      Throws:
      RemoteException - RemoteException
    • removeFromFolder

      void removeFromFolder(int token, String folderTableDDC, String documentSysRowId, String documentDDC, String folderId) throws RemoteException
      Remove the document filing from the given node.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      documentSysRowId - Document SysRowId
      documentDDC - Document DDC name
      folderId - Folder ID
      Throws:
      RemoteException - RemoteException
    • moveToFolder

      void moveToFolder(int token, String folderTableDDC, String documentId, String documentDDC, String folderId, String destinationId) throws RemoteException
      Moves the document’s filing to the given node. It is removed from the original folder. Both source node and destination node must exist.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      documentId - Document SysRowId
      documentDDC - Document DDC name
      folderId - Source folder ID
      destinationId - Destination folder ID
      Throws:
      RemoteException - RemoteException
    • getDocumentFolders

      List<SaDocumentInfo> getDocumentFolders(int token, String folderTableDDC, String documentDDC, String sysRowId) throws RemoteException
      Returns a list of folder properties which contains all nodes the document is contained in. The list is returned only for one node table, so if the document is filed in multiple node tables, this must be queried separately.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      documentDDC - Document DDC
      sysRowId - Document sysRowId
      Returns:
      List of folder properties
      Throws:
      RemoteException - RemoteException
    • getDocumentFolderCount

      long getDocumentFolderCount(int token, String folderTableDDC, String documentDDC, String sysRowId) throws RemoteException
      Returns the total count over all folders from all users in which the specified document is contained in.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      documentDDC - Document DDC
      sysRowId - Document sysRowId
      Returns:
      folder count
      Throws:
      RemoteException - RemoteException
    • getFolderInfo

      SaDocumentInfo getFolderInfo(int token, String folderTableDDC, String folderId, boolean forceLoadVariables) throws RemoteException
      Reads the folder info object for the given folder.
      Parameters:
      token - User token
      folderTableDDC - Folder table
      folderId - Folder id
      forceLoadVariables - if true, variables will be loaded from medium if the DDC does not contain the SYSPROPERTIES field
      Returns:
      Folder info object
      Throws:
      RemoteException - Remote exception
    • setFolderAcl

      void setFolderAcl(int token, String folderTableDDC, String folderId, String aclName) throws RemoteException
      Sets an ACL for the given folder. The node’s SysACLUserList is recalculated, and if the node has children, the same is true for all the node’s children.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      aclName - ACL name
      Throws:
      RemoteException - RemoteException
    • getFolderRights

      SaDocAccessData getFolderRights(int token, String folderTableDDC, String folderId) throws RemoteException
      Returns the rights mask for the given folder and user. The effective rights are calculated by using ACL inheritance.
      Parameters:
      token - user token
      folderTableDDC - Folder table
      folderId - Folder ID
      Returns:
      Folder access data
      Throws:
      RemoteException - RemoteException
    • getSystemFiles

      List<String> getSystemFiles(int clientToken, SystemFileKind kind, String filter) throws RemoteException
      Gets the system files of a specific kind.
      Parameters:
      clientToken - The current user token.
      kind - the kind of systemfiles to read.
      filter - A filter string. Only files will be returned, that match the filter. To get all systemfiles of a kind set filter to the empty string.
      Returns:
      The system files of a specific kind.
      Throws:
      RemoteException - RemoteException
    • logClientEvent

      void logClientEvent(int token, String hdoc, SaConstants.ProtoEvents event, String remark) throws RemoteException
      Adds an audit log event.
      Parameters:
      token - user token
      hdoc - Document HDOC
      event - Event type
      remark - Remark
      Throws:
      RemoteException - Remote exception
    • changePassword

      void changePassword(String user, String oldPassword, String client, String newPassword) throws RemoteException
      Changes the password of an existing user. This has to be done before a call to logon(Credentials) was successfully invoked.
      Parameters:
      user - The name of the user.
      oldPassword - The old password. This parameter is required, since the password should only be changed by the user himself
      client - The client of the actions
      newPassword - The new password
      Throws:
      RemoteException - exception
    • getAuthorizedUsers

      List<UsersRights> getAuthorizedUsers(int clientToken, String hDoc, String rights, MatchKind match) throws RemoteException
      Returns the users, that have specific rights on a document.
      Parameters:
      clientToken - The current user token.
      hDoc - The id of the document.
      rights - The rights the requested users should have.
      match - How the rights are matched: MKONEOF - find all users that have one of the specified rights MKEXACT - find all users that have exactly the specified rights MKATLEAST - find all users that have at least the specified rights
      Returns:
      The users, that have specific rights on the document or null if the document has no acl set. In this case everyone has every right on the document.
      Throws:
      RemoteException - exception
    • getArchivedSize

      int getArchivedSize(int clientToken, String hDoc) throws RemoteException
      Returns the total document size in archive.
      Parameters:
      clientToken - The current user token.
      hDoc - The document whose size is wanted.
      Returns:
      The total document size in archive.
      Throws:
      RemoteException - exception
    • getFolderClass

      SaFolderClass getFolderClass(int clientToken, String className) throws RemoteException, com.lexmark.saperion.exceptions.system.BackendSystemException
      Reads the folder class with the given name.
      Parameters:
      clientToken - The current user token.
      className - Class name in dotted notation
      Returns:
      Folder classs
      Throws:
      RemoteException - exception on reading folder class
      com.lexmark.saperion.exceptions.system.BackendSystemException
    • searchFolderClass

      Set<SaFolderClass> searchFolderClass(int clientToken, SaFolderClassSearchInfo searchInfo) throws RemoteException, com.lexmark.saperion.exceptions.system.BackendSystemException
      Searches for folder classes with the specified properties.
      Parameters:
      clientToken - The current user token.
      searchInfo - bean that contains properties to search for
      Returns:
      set of classes that match the specified properties
      Throws:
      RemoteException - exception when searching for classes
      com.lexmark.saperion.exceptions.system.BackendSystemException
    • storeSystemFile

      void storeSystemFile(int clientToken, SystemFileKind kind, String name, byte[] data) throws RemoteException
      Stores a system file of a specific kind.
      Parameters:
      clientToken - The current user token.
      kind - The kind of systemfile to store.
      name - The name of the file. This has to be a filename without path and extension.
      data - The content of the file to save.
      Throws:
      RemoteException - exception
    • loadSystemFile

      byte[] loadSystemFile(int clientToken, SystemFileKind kind, String name) throws RemoteException
      Loads a system file of a specific kind.
      Parameters:
      clientToken - The current user token.
      kind - The kind of system file to load
      name - The name of the file to load.
      Returns:
      an InputStream that holds the content of the file.
      Throws:
      RemoteException - exception
    • getRMIVersion

      String getRMIVersion() throws RemoteException
      Determine the RMI interface version.
      Returns:
      RMI interface version.
      Throws:
      RemoteException - exception
    • getFolderUpdateInfo

      Set<FolderUpdateInfo> getFolderUpdateInfo(int clientToken, Map<String,Long> sysrowids) throws RemoteException
      Calculates a cut set of folders that shall be refreshed on client side. FolderUpdateInfo objects hold information for workflow folders and other types.
      Parameters:
      clientToken - The current user token.
      sysrowids - Map of SYSROWIDs with time stamps to check against the cache map of changed folders.
      Returns:
      Cut set of given List of Folder SYSROWIDs and the ones laying in the cache.
      Throws:
      RemoteException - exception
      See Also:
    • setVariables

      void setVariables(int clientToken, int element, Map<String,String> variables) throws RemoteException
      Method to set the Variables for an Content-Object or the Structure itself.
      Parameters:
      clientToken - The current user token.
      element - Element Number where the Variables should be set to. (0 = Structure)
      variables - Map of Key-Value Pairs for setting Variables
      Throws:
      RemoteException - exception
    • checkSapUrl

      SapDocInfo checkSapUrl(int clientToken, String url) throws RemoteException
      Checks the given SAP URL on the R/Link server and returns, if successfull, the HDOC and the DDC. If not, null will be returned.
      Parameters:
      clientToken - The current user token.
      url - SAP URL
      Returns:
      Document Info
      Throws:
      RemoteException - exception
    • newInvoke

      <ResultType extends Serializable, ExceptionType extends Exception> ResultType newInvoke(int clientToken, com.lexmark.saperion.remote.common.operations.Operation<ResultType,ExceptionType,com.lexmark.saperion.remote.common.Connection> operation) throws RemoteException, ExceptionType
      This method invokes an Operation that throws ecm exceptions on the server side.
      Type Parameters:
      ResultType - the type of the result of the operation
      Parameters:
      clientToken - the used user token
      operation - the operation to invoke
      Returns:
      the result of the operation
      Throws:
      RemoteException - on network errors
      ExceptionType - when the operation threw an exception it will be thrown
    • invoke

      <T extends Serializable> T invoke(int clientToken, com.lexmark.saperion.remote.common.operations.Operation<T,SaBasicException,LegacyConnection> operation) throws RemoteException, SaBasicException
      This method invokes an Operation on the server side.
      Type Parameters:
      T - The return type
      Parameters:
      operation - The operation to invoke
      clientToken - The current user token.
      Returns:
      The result of the invocation of the operation
      Throws:
      RemoteException
      SaBasicException
    • sendBarcode

      void sendBarcode(int clientToken, String indexMask, String docUid, String contentRep, String sid, String docType, String value, int mandant) throws RemoteException
      Send barcode to SAP.
      Parameters:
      clientToken - The current user token.
      indexMask - Index mask name
      docUid - Document UID
      contentRep - SAP Content repository
      sid - SAP ID
      docType - Document type
      value - Value
      mandant - Mandant name
      Throws:
      RemoteException - exception
    • setEventsEnabled

      void setEventsEnabled(int clientToken, boolean enabled) throws RemoteException
      Sets whether events (e.g. for the IS) should be enabled for the current session.
      Parameters:
      clientToken - The current user token.
      enabled - true, if events should be enabled, otherwise false.
      Throws:
      RemoteException
    • getEventsEnabled

      boolean getEventsEnabled(int clientToken) throws RemoteException
      Returns whether events (e.g. for the IS) are enabled for the current session.
      Parameters:
      clientToken - The current user token.
      Returns:
      true, if events are enabled, otherwise false.
      Throws:
      RemoteException
    • getDDC

      DDC getDDC(int clientToken, String ddcName) throws RemoteException
      Returns information about the specified DDC.
      Parameters:
      clientToken - The current user token.
      ddcName - the name of the DDC
      Returns:
      DDC information
      Throws:
      RemoteException - system error when retrieving information about requested DDC
    • setDocumentState

      void setDocumentState(int clientToken, String ddcName, String hdoc, String value) throws RemoteException
      Sets the SYSDOCUMENTSTATE value of a document to the specified value without creating a new revision.
      Parameters:
      clientToken - the current user token
      ddcName - DDC name of the document
      hdoc - HDOC of the document
      value - value to set
      Throws:
      RemoteException - system error when setting document state
    • getInjector

      Injector getInjector(int clientToken) throws RemoteException
      This method returns the injector for the given session. Internal use only.
      Parameters:
      clientToken - the token of the session
      Returns:
      the injector of the session
      Throws:
      RemoteException - rmi errors
    • getStreamingConfiguration

      com.lexmark.saperion.remote.common.operations.document.content.stream.StreamingConfiguration getStreamingConfiguration() throws RemoteException, com.lexmark.saperion.exceptions.EcmException
      This method returns the current streaming configuration.
      Returns:
      the current streaming configuration
      Throws:
      RemoteException
      com.lexmark.saperion.exceptions.EcmException
    • getFullTextFields

      Map<String,String> getFullTextFields(int token, String ddcName, List<String> fullTextFields, String hdoc) throws RemoteException, com.lexmark.saperion.exceptions.EcmException
      Fetches values of Full text columns
      Parameters:
      token - Rmi Token
      ddcName - name of the DDC
      fullTextFields - List of Fields which are of Text retrieval type. Make sure to prefix SaConstants.FULL_TEXT_COLUMN_PREFIX
      hdoc - hdoc of the document
      Returns:
      Map full text coulmn and corresponding value
      Throws:
      RemoteException
      com.lexmark.saperion.exceptions.EcmException
    • getExternalStorageFoldersForUpload

      List<SaperionExternalStorageMappingInfo> getExternalStorageFoldersForUpload(int token, ExternalStorageType storageType) throws RemoteException
      Fetches all folders of provided External Storage from where documents need to be uploaded
      Parameters:
      token - RMI token
      storageType - external storage type
      Returns:
      list of External Storage folder details
      Throws:
      RemoteException
    • getExternalStorageFoldersForUpload

      List<SaperionExternalStorageMappingInfo> getExternalStorageFoldersForUpload(int token) throws RemoteException
      Fetches all folders of all External Storage services from where documents need to be uploaded
      Parameters:
      token - RMI token
      Returns:
      list of External Storage folder details
      Throws:
      RemoteException
    • getExternalStorageMapping

      SaperionExternalStorageMappingInfo getExternalStorageMapping(int token, String sysRowId) throws RemoteException
      Fetches the external storage mapping for the provided SysRowId
      Parameters:
      token -
      sysRowId -
      Returns:
      mapping object
      Throws:
      RemoteException
    • createExternalStorageFolderMapping

      void createExternalStorageFolderMapping(int token, SaperionExternalStorageMappingInfo mappingInfo) throws RemoteException
      Stores the mapping information about Saperion document and External Storage folder
      Parameters:
      token - RMI token
      mappingInfo - mapping information about Saperion document and External Storage folder
      Throws:
      RemoteException
    • updateExternalStorageUploadStatus

      void updateExternalStorageUploadStatus(int token, String folderId, ExternalStorageDocUploadStatus status, ExternalStorageType storageType) throws RemoteException
      Updates the upload status of External Storage folder
      Parameters:
      token - RMI token
      folderId - folderId whose status needs to be updated
      status -
      storageType -
      Throws:
      RemoteException
    • deleteExternalStorageFolderMapping

      int deleteExternalStorageFolderMapping(int token, Date expiryTime, List<ExternalStorageDocUploadStatus> statusList) throws RemoteException
      Deletes external storage mappings for given status and older than the given time
      Parameters:
      token - RMI token
      expiryTime - all mappings older than this time will be deleted
      Throws:
      RemoteException
    • getCurrentUserRole

      com.lexmark.saperion.administration.RoleType getCurrentUserRole(int token) throws RemoteException
      Parameters:
      token - RMI token
      Returns:
      the effective role (combined rights of all roles / profiles) of the current logged-in user
      Throws:
      RemoteException