Class HylandViewerUtil

java.lang.Object
com.saperion.ngc.viewer.hylandviewer.HylandViewerUtil
All Implemented Interfaces:
Serializable

public final class HylandViewerUtil extends Object implements Serializable
Utility class for the Hyland Viewer.
Author:
schowdhury
See Also:
  • Constructor Details

    • HylandViewerUtil

      public HylandViewerUtil(jakarta.servlet.http.HttpServletRequest httpRequest, jakarta.servlet.http.HttpSession session)
  • Method Details

    • constructViewerDocumentUrl

      public String constructViewerDocumentUrl(jakarta.servlet.http.HttpServletRequest httpRequest, String sessionId)
      Construct the url to retrieve the document with the given sessionId
      Parameters:
      sessionId - the id of the document from hyland rendering and conversion service
      Returns:
      url as string
    • constructViewerDocumentUrl

      public String constructViewerDocumentUrl(jakarta.servlet.http.HttpServletRequest httpRequest, String sessionId, String revisionId, int elementNumber, String name)
      Construct the url to retrieve the document with the given sessionId
      Parameters:
      sessionId - the id of the document from hyland rendering and conversion service
      revisionId - the revisionId of the document
      elementNumber - the elementNumber of the document
      name - the name of the document
      Returns:
      url as string
    • constructViewerTempDocumentUrl

      public String constructViewerTempDocumentUrl(jakarta.servlet.http.HttpServletRequest httpRequest, String sessionId)
      Construct the temporary document url with the given session id of the document
      Parameters:
      sessionId - the id of the document from hyland rendering and conversion service
      Returns:
      url as string
    • uploadDocument

      public String uploadDocument(String revisionId, int elementNumber, String name, boolean editMode)
      Get the session id of a document
      Parameters:
      revisionId - hdoc of a structure
      elementNumber - element ID. Used only for structured documents to identify the page
      name - name of an element in a structured document
      Returns:
      the session id of a document
    • uploadTemporaryDocument

      public String uploadTemporaryDocument(TemporaryDocumentId id)
      Get the session id of a temporary document
      Parameters:
      id - a reference to the temporary document
      Returns:
      the session id of a temporary document
    • getIniAnnotation

      public AnnotationDocInfo getIniAnnotation(String revisionId) throws AuthenticationException, SystemException
      Get the annotation of a document
      Parameters:
      revisionId - hdoc of a structure
      Returns:
      AnnotationDocInfo the annotation information comprising of ini string and document dimension
      Throws:
      AuthenticationException
      SystemException
    • getStructureInfo

      public DocumentStructureInfo getStructureInfo(String revisionId)
      Get the structure information of a document
      Parameters:
      revisionId - hdoc of a structure
      Returns:
      DocumentStructureInfo the structure information of a document