Class HylandViewerUtil
java.lang.Object
com.saperion.ngc.viewer.hylandviewer.HylandViewerUtil
- All Implemented Interfaces:
Serializable
Utility class for the Hyland Viewer.
- Author:
- schowdhury
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionHylandViewerUtil(jakarta.servlet.http.HttpServletRequest httpRequest, jakarta.servlet.http.HttpSession session) -
Method Summary
Modifier and TypeMethodDescriptionconstructViewerDocumentUrl(jakarta.servlet.http.HttpServletRequest httpRequest, String sessionId) Construct the url to retrieve the document with the given sessionIdconstructViewerDocumentUrl(jakarta.servlet.http.HttpServletRequest httpRequest, String sessionId, String revisionId, int elementNumber, String name) Construct the url to retrieve the document with the given sessionIdconstructViewerTempDocumentUrl(jakarta.servlet.http.HttpServletRequest httpRequest, String sessionId) Construct the temporary document url with the given session id of the documentgetDocumentArchiveMetaInfo(DocumentId docId, boolean currentRevision) Get the document archive meta information of a specific document.getIniAnnotation(String revisionId, String sessionId, int elementNumber) Get the annotation of a documentgetOpenDocumentBean(DocumentId docId, boolean currentRevision, boolean editMode) Get a OpenDocumentBean for a specific document id.getStructureInfo(String revisionId, String sessionId, int elementNumber) Get the structure information of a documentgetUpdatedDocumentId(DocumentId docId) Get the updated document id.booleanisEditable(jakarta.servlet.http.HttpServletRequest request, ResultProperties documentInfo) Check whether a document is editable.uploadDocument(String revisionId, int elementNumber, String name, boolean editMode) Get the session id of a documentGet the session id of a temporary document
-
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 servicerevisionId- the revisionId of the documentelementNumber- the elementNumber of the documentname- 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
Get the session id of a document- Parameters:
revisionId- hdoc of a structureelementNumber- element ID. Used only for structured documents to identify the pagename- name of an element in a structured document- Returns:
- the session id of a document
-
uploadTemporaryDocument
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, String sessionId, int elementNumber) throws AuthenticationException, SystemException Get the annotation of a document- Parameters:
revisionId- hdoc of a structuresessionId- the id of the document from hyland rendering and conversion serviceelementNumber- the element number of the document that is used only for structured documents to identify the page- Returns:
- AnnotationDocInfo the annotation information comprising of ini string and document dimension
- Throws:
AuthenticationExceptionSystemException
-
getStructureInfo
public DocumentStructureInfo getStructureInfo(String revisionId, String sessionId, int elementNumber) Get the structure information of a document- Parameters:
revisionId- hdoc of a structuresessionId- the id of the document from hyland rendering and conversion serviceelementNumber- the element number of the document that is used only for structured documents to identify the page- Returns:
- DocumentStructureInfo the structure information of a document
-
getDocumentArchiveMetaInfo
public DocumentArchiveMetaInfo getDocumentArchiveMetaInfo(DocumentId docId, boolean currentRevision) throws SystemException, AuthenticationException Get the document archive meta information of a specific document.- Parameters:
docId-- Returns:
- Throws:
SystemExceptionAuthenticationException
-
getUpdatedDocumentId
public DocumentId getUpdatedDocumentId(DocumentId docId) throws SystemException, AuthenticationException, DocumentIdentificationException Get the updated document id.- Parameters:
docId-- Returns:
- Throws:
SystemExceptionAuthenticationExceptionDocumentIdentificationException
-
getOpenDocumentBean
public OpenDocumentBean getOpenDocumentBean(DocumentId docId, boolean currentRevision, boolean editMode) throws SystemException, AuthenticationException Get a OpenDocumentBean for a specific document id.- Parameters:
docId-currentRevision-editMode-- Returns:
- Throws:
SystemExceptionAuthenticationException
-
isEditable
public boolean isEditable(jakarta.servlet.http.HttpServletRequest request, ResultProperties documentInfo) throws SystemException, AuthenticationException, DocumentIdentificationException Check whether a document is editable.- Parameters:
request-documentInfo-- Returns:
- Throws:
SystemExceptionAuthenticationExceptionDocumentIdentificationException
-