public class SaWsVersionService extends AbstractService
configured
Constructor and Description |
---|
SaWsVersionService()
Constructor.
|
Modifier and Type | Method and Description |
---|---|
SaWsContent |
getContent(int token,
String xhdoc,
int elementNumber)
Loads a document version from the backend system.
|
String |
getContentFilename(int token,
String xhdoc,
int elementNumber)
Loads the filename for a document from the backend system.
|
SaWsVersionData |
getMetadata(int token,
String xhdoc)
Reads the version metadata of the document with the given ID.
|
SaWsContent |
getReleasedDocument(int token,
String xhdoc,
int elementNumber)
Gets the content stream of the last released document.
|
List<String> |
getVersionIDs(int token,
String definition,
String sysrowid)
Reads the version IDs of the given document.
|
void |
releaseDocument(int token,
String ddcName,
String xhdoc,
String comment)
Release the document by given xhdoc.
|
SaWsSaveInfo |
restore(int token,
String xhdoc)
Restores the version with the given HDOC.
|
addToRequest, getConnection, getSession, isConfigured
public SaWsSaveInfo restore(int token, String xhdoc) throws SaWsAuthenticationException, SaWsDBException, SaWsRepositoryException, SaWsException
token
- to identify the session.xhdoc
- Version HDOCSaWsDBException
- if a database error occurs.SaWsAuthenticationException
- if an authentication error occurs.SaWsRepositoryException
- if a repository error occurs.SaWsException
SaClassicConnector.restoreVersion(java.lang.String)
public SaWsVersionData getMetadata(int token, String xhdoc) throws SaWsAuthenticationException, SaWsDBException, SaWsRepositoryException, SaWsException
token
- to identify the session.xhdoc
- Version IDSaWsDBException
- if a database error occurs.SaWsAuthenticationException
- if an authentication error occurs.SaWsRepositoryException
- if a repository error occurs.SaWsException
SaClassicConnector.readVersionMetadata(java.lang.String)
public SaWsContent getContent(int token, String xhdoc, int elementNumber) throws SaWsAuthenticationException, SaWsDBException, SaWsRepositoryException, SaWsException
token
- to identify the session.xhdoc
- Version IDelementNumber
- Element numberSaWsDBException
- if a database error occurs.SaWsAuthenticationException
- if an authentication error occurs.SaWsRepositoryException
- if a repository error occurs.SaWsException
SaClassicConnector.readVersionDocument(java.lang.String, int)
public String getContentFilename(int token, String xhdoc, int elementNumber) throws SaWsAuthenticationException, SaWsDBException, SaWsRepositoryException, SaWsException
token
- Token for the open sessionxhdoc
- ID for the document which contains the contentelementNumber
- number element which should be readSaWsDBException
- if a database error occurs.SaWsAuthenticationException
- if an authentication error occurs.SaWsRepositoryException
- if a repository error occurs.SaWsException
SaClassicConnector.readVersionDocumentFilename(java.lang.String,
int)
public List<String> getVersionIDs(int token, String definition, String sysrowid) throws SaWsAuthenticationException, SaWsRepositoryException, SaWsException
token
- to identify the session.definition
- definition which is used for finding the versions of the documentsysrowid
- The ID of the documentSaWsAuthenticationException
- if an authentication error occurs.SaWsRepositoryException
- if a repository error occurs.SaWsException
SaClassicConnector.getVersionIDs(java.lang.String,
java.lang.String)
public void releaseDocument(int token, String ddcName, String xhdoc, String comment) throws SaWsException
token
- the token to identify the session.ddcName
- the ddc namexhdoc
- the xhdoc the ID of the document.comment
- The comment for the new reversionSaWsException
- if an unexpected error occurs, e.g. when release feature is not configuredpublic SaWsContent getReleasedDocument(int token, String xhdoc, int elementNumber) throws SaWsException
token
- the token to identify the session.xhdoc
- the xhdoc the ID of the document.elementNumber
- position of the element to return in the structured document.SaWsException
- if an unexpected error occurs, e.g. when release feature is not configuredCopyright © 2020 Hyland Software Germany GmbH. All rights reserved.