public final class VirtualViewerUtil extends Object implements Serializable
Constructor and Description |
---|
VirtualViewerUtil(javax.servlet.http.HttpServletRequest request)
Instantiates a new virtual viewer util.
|
Modifier and Type | Method and Description |
---|---|
String |
getAnnotationsPostUrl(String popupId)
Gets the URL to be used when posting annotations.
|
String |
getBaseUrl()
Gets the base url.
|
String |
getCodebase() |
String |
getCustomAssetsFile()
Gets the name of the custom assets file for the current locale.
|
String |
getDocIdWithoutElement(OpenDocumentBean bean)
Gets the doc-id without the element-id.
|
static String |
getPropertiesAsAppletParams(String filename)
Returns a string containing all applet parameters as read from the specified file.
|
static DocumentId |
getReleasedHdoc(DocumentId documentId,
OpenDocumentBean openDocumentBean,
DocumentService docService)
Gets the released hdoc.
|
static Map<Integer,Integer> |
getRotationAngles(OpenDocumentBean bean)
Gets the rotation angles from the bean.
|
String |
getServletUrl()
Gets the url of the retrieval-servlet.
|
Set<String> |
getSupportedFormats() |
boolean |
isSupportedFormat(DocumentArchiveMetaInfo.ElementArchiveMetaInfo elementInfo)
Checks if is supported format.
|
boolean |
isSupportedFormatByFilename(String filename)
Checks if the format by the given filename is supported by the virtual viewer.
|
static void |
rememberRotationForPage(OpenDocumentBean bean,
int page,
int angle)
Stores the angle by wich the specified page was rotated.
|
public VirtualViewerUtil(javax.servlet.http.HttpServletRequest request)
request
- the requestpublic String getCodebase()
public String getBaseUrl()
public String getServletUrl()
public String getCustomAssetsFile()
public static String getPropertiesAsAppletParams(String filename)
filename
- file to readpublic String getAnnotationsPostUrl(String popupId)
popupId
- id of the viewer-popuppublic String getDocIdWithoutElement(OpenDocumentBean bean)
bean
- the document beanpublic static DocumentId getReleasedHdoc(DocumentId documentId, OpenDocumentBean openDocumentBean, DocumentService docService) throws AuthenticationException, SystemException
documentId
- the document id to get current hdocopenDocumentBean
- the open document bean to check edit modedocService
- the doc service to make backend call to get possible released hdocAuthenticationException
- the authentication exceptionSystemException
- the system exceptionpublic boolean isSupportedFormat(DocumentArchiveMetaInfo.ElementArchiveMetaInfo elementInfo)
elementInfo
- the filenamepublic boolean isSupportedFormatByFilename(String filename)
filename
- The file to check the extension of.public static void rememberRotationForPage(OpenDocumentBean bean, int page, int angle)
bean
- current OpenDocumentBeanpage
- current pageangle
- last anglepublic static Map<Integer,Integer> getRotationAngles(OpenDocumentBean bean)
bean
- current OpenDocumentBeanCopyright © 2021 Hyland Software Germany GmbH. All rights reserved.