public class RmiClientDocumentService extends AbstractRmiClientService implements DocumentService
DocumentService provides document functionality by delegating to a remote saperion system via RMI.connection| Constructor and Description |
|---|
RmiClientDocumentService(Connection connection) |
| Modifier and Type | Method and Description |
|---|---|
com.lexmark.saperion.document.DocumentStoreInformationType |
createDocument(com.lexmark.saperion.document.DocumentDefinitionReferenceType definition,
Map<String,Object> indexData,
com.lexmark.saperion.document.DocumentElementType rootElement)
This method stores a new document with the given data in the backend.
|
com.lexmark.saperion.document.DocumentRevisionReferenceType |
getLatestRevisionId(com.lexmark.saperion.document.DocumentReferenceType documentId)
This method returns the id of the latest revision of the document given by its id.
|
com.lexmark.saperion.document.DocumentRevisionType |
loadDocument(com.lexmark.saperion.document.DocumentReferenceType documentId,
com.lexmark.saperion.document.LoadKindEnumeration loadKind)
Loads the latest
document revision with the given
document id. |
com.lexmark.saperion.document.DocumentRevisionType |
loadDocument(com.lexmark.saperion.document.DocumentRevisionReferenceType revisionId,
com.lexmark.saperion.document.LoadKindEnumeration loadKind)
Loads a complete
document revision given its
revision id. |
InputStream |
readDocumentElementContent(com.lexmark.saperion.document.DocumentReferenceType documentId,
com.lexmark.saperion.document.DocumentElementReferenceType documentElementId)
Opens the content of the document element identified by the given id for reading and returns an
input stream for that data. |
List<com.lexmark.saperion.document.DocumentRevisionReferenceType> |
searchDocuments(com.lexmark.saperion.document.DocumentDefinitionReferenceType definitionName,
QueryExpression<Boolean> filter)
Loads all documents for which the given filter holds
|
com.lexmark.saperion.document.DocumentRevisionType |
searchUniqueDocument(com.lexmark.saperion.document.DocumentDefinitionReferenceType definitionName,
QueryExpression<Boolean> filter,
com.lexmark.saperion.document.LoadKindEnumeration loadKind)
Loads the unique document for which the given filter holds.
|
mapSystemExceptionpublic RmiClientDocumentService(Connection connection)
public com.lexmark.saperion.document.DocumentRevisionReferenceType getLatestRevisionId(com.lexmark.saperion.document.DocumentReferenceType documentId)
throws SaBasicException
DocumentServicegetLatestRevisionId in interface DocumentServicedocumentId - the id of the document to get the latest revision id forSaBasicExceptionpublic com.lexmark.saperion.document.DocumentRevisionType loadDocument(com.lexmark.saperion.document.DocumentRevisionReferenceType revisionId,
com.lexmark.saperion.document.LoadKindEnumeration loadKind)
throws SaBasicException
DocumentServicedocument revision given its
revision id.loadDocument in interface DocumentServicerevisionId - the revision id of the document to loadSaBasicExceptionpublic com.lexmark.saperion.document.DocumentRevisionType loadDocument(com.lexmark.saperion.document.DocumentReferenceType documentId,
com.lexmark.saperion.document.LoadKindEnumeration loadKind)
throws SaBasicException
DocumentServicedocument revision with the given
document id.loadDocument in interface DocumentServicedocumentId - the id of the documentSaBasicExceptionpublic com.lexmark.saperion.document.DocumentRevisionType searchUniqueDocument(com.lexmark.saperion.document.DocumentDefinitionReferenceType definitionName,
QueryExpression<Boolean> filter,
com.lexmark.saperion.document.LoadKindEnumeration loadKind)
throws SaBasicException
DocumentServicesearchUniqueDocument in interface DocumentServicedefinitionName - reference to the document definition to search in.filter - a QueryExpression of type boolean that uniquely identifies the documentSaBasicExceptionpublic List<com.lexmark.saperion.document.DocumentRevisionReferenceType> searchDocuments(com.lexmark.saperion.document.DocumentDefinitionReferenceType definitionName, QueryExpression<Boolean> filter) throws SaBasicException
DocumentServicesearchDocuments in interface DocumentServicedefinitionName - the document definition to search in.filter - a QueryExpression of type boolean that is true for all wanted documentsrevision ids of documents that match the given filterSaBasicExceptionpublic InputStream readDocumentElementContent(com.lexmark.saperion.document.DocumentReferenceType documentId, com.lexmark.saperion.document.DocumentElementReferenceType documentElementId) throws SaBasicException
DocumentServiceinput stream for that data. If the element is chunked the resulting stream will stream
over all the chunks.readDocumentElementContent in interface DocumentServicedocumentId - the id of the document the element to read belongs todocumentElementId - the id of the document element to read frominput stream for the content of the given document elementSaBasicExceptionpublic com.lexmark.saperion.document.DocumentStoreInformationType createDocument(com.lexmark.saperion.document.DocumentDefinitionReferenceType definition,
Map<String,Object> indexData,
com.lexmark.saperion.document.DocumentElementType rootElement)
throws SaBasicException
DocumentServicecreateDocument in interface DocumentServicedefinition - a reference to the definition to store the document inindexData - the index data the document will hold.rootElement - the documents root elementSaBasicExceptionCopyright © 2016 SAPERION AG. All rights reserved.