Package com.saperion.ngc.sapviewer
Class SAPViewerUrl
- java.lang.Object
-
- com.saperion.ngc.sapviewer.SAPViewerUrl
-
public class SAPViewerUrl extends java.lang.Object
This is the parser for SAPViewer URLs.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DDC_TAG
URL tag for DDC name.static java.lang.String
DOCID_TAG
URL tag for document ID.static java.lang.String
DOWNLOAD_ALLOWED
Property in control bean used to store if downloading is allowed or not.static java.lang.String
LINKTAG
URL tag for WebLink mode.static java.lang.String
MAINTAG
URL tag for WebView mode.static java.lang.String
SAPVIEWER_PREFIX
Prefix for client instance ID of applet.static java.lang.String
USER_TAG
URL tag for user name.
-
Constructor Summary
Constructors Constructor Description SAPViewerUrl()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description OpenDocumentBean
createControlBeanAndLogin(java.lang.String url, javax.servlet.http.HttpServletRequest servletRequest, java.lang.String viewerId)
Parses the SAPViewer-URL, performs a login if required and created the viewer-control-bean.static java.lang.String
getRandomViewerId()
-
-
-
Field Detail
-
DOWNLOAD_ALLOWED
public static final java.lang.String DOWNLOAD_ALLOWED
Property in control bean used to store if downloading is allowed or not.- See Also:
- Constant Field Values
-
MAINTAG
public static final java.lang.String MAINTAG
URL tag for WebView mode.- See Also:
- Constant Field Values
-
LINKTAG
public static final java.lang.String LINKTAG
URL tag for WebLink mode.- See Also:
- Constant Field Values
-
DOCID_TAG
public static final java.lang.String DOCID_TAG
URL tag for document ID.- See Also:
- Constant Field Values
-
USER_TAG
public static final java.lang.String USER_TAG
URL tag for user name.- See Also:
- Constant Field Values
-
DDC_TAG
public static final java.lang.String DDC_TAG
URL tag for DDC name.- See Also:
- Constant Field Values
-
SAPVIEWER_PREFIX
public static final java.lang.String SAPVIEWER_PREFIX
Prefix for client instance ID of applet.- See Also:
- Constant Field Values
-
-
Method Detail
-
createControlBeanAndLogin
public OpenDocumentBean createControlBeanAndLogin(java.lang.String url, javax.servlet.http.HttpServletRequest servletRequest, java.lang.String viewerId) throws AuthenticationException, SystemException, DocumentLockException, SapViewerUrlException
Parses the SAPViewer-URL, performs a login if required and created the viewer-control-bean.- Parameters:
url
- the URL to parseservletRequest
- the current request sent from the clientviewerId
- the ID of the current viewer- Returns:
- the bean containing the information about the document to open
- Throws:
AuthenticationException
- Exception when logging inSystemException
- Exception when parsing the url or when reading the documentDocumentLockException
- document is lockedSapViewerUrlException
- when the url was invalid
-
getRandomViewerId
public static java.lang.String getRandomViewerId()
- Returns:
- a string to be used as client instance id for the applet
-
-