Package com.saperion.connector.rmi
Class AbstractQueryRMIClientCommand
- java.lang.Object
-
- com.saperion.connector.rmi.AbstractRMIClientCommand
-
- com.saperion.connector.rmi.AbstractFolderRMIClientCommand
-
- com.saperion.connector.rmi.AbstractDocRMIClientCommand
-
- com.saperion.connector.rmi.AbstractQueryRMIClientCommand
-
- All Implemented Interfaces:
SaRMIClientCommand
- Direct Known Subclasses:
AbstractWfRMIClientCommand
public abstract class AbstractQueryRMIClientCommand extends AbstractDocRMIClientCommand
Class representing the query operations of the backend.
-
-
Field Summary
-
Fields inherited from class com.saperion.connector.rmi.AbstractRMIClientCommand
APPEND_CONTENT, appl, credentials, LOGGER, props, session, sessionInfo, sysConnector, writeBufferSize
-
-
Constructor Summary
Constructors Constructor Description AbstractQueryRMIClientCommand()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
finishSQLTransaction(boolean commit, java.lang.String ddcName)
Finish SQL transaction.java.lang.String
getFulltext(java.lang.String ddcName, java.lang.String sysRowId, java.lang.String hdoc, java.lang.String fieldName, long length)
Reads the fulltext information for the given document with the given SYSROWID in the given DDC.java.lang.String
getHDocForSysRowId(java.lang.String sysRowId, java.lang.String ddcName)
Searchs the HDOC for the given SysRowId.java.util.List<java.lang.String>
getIdsFromQuery(java.lang.String query)
Executes a HQL query and returns the results as a string list.java.util.List<SaDocumentInfo>
getStringQueryResult(SaQueryInfo hqlQuery)
Executes a given HQL string and returns the results as list.java.util.List<java.lang.String>
getVersionList(java.lang.String ddcName, java.lang.String sysrowID)
Reads the versionlist for the given document.SaPropertyValue[]
readDocumentMetadata(java.lang.String sysRowId, java.lang.String ddcName, java.lang.String[] fields)
Reads the meta data of the document with the given ID.void
startSQLTransaction(java.lang.String ddcName)
Start SQL transaction.-
Methods inherited from class com.saperion.connector.rmi.AbstractDocRMIClientCommand
cacheDocument, checkoutDocument, checkoutDocument, checkSapUrl, clearContent, closeDocument, createDocument, createExternalStorageFolderMapping, createLink, deleteDocument, deleteExternalStorageFolderMapping, discardDocument, dsicardCheckout, finishTransaction, getACLNames, getACLRights, getAcls, getAllACLs, getAnnotations, getExternalStorageFoldersForUpload, getExternalStorageFoldersForUpload, getExternalStorageMapping, getInvolvedUsers, getLockInfo, getLocks, getLocks, getNodeAccessData, getThumbnail, lockNode, logClientEvent, readDocumentFirst, readDocumentFirst, readDocumentNext, readVersionMetadata, readVersionMetadata, releaseDocument, removeElement, removeElement, restoreVersion, saveDocument, saveDocument, setACLName, setAnnotations, setElementMark, setVariables, startTransaction, storeDocument, storeDocument, unlockNode, updateExternalStorageUploadStatus, writeContent, writeContent, writeContent, writeContent
-
Methods inherited from class com.saperion.connector.rmi.AbstractFolderRMIClientCommand
addToFolder, copyFolder, createFolder, deleteFolder, getDocumentFolderCount, getDocumentFolders, getFolderChildren, getFolderClass, getFolderFromPath, getFolderInfo, getFolderParent, getFolderRights, getFolderUpdateInfo, moveFolder, moveToFolder, removeFromFolder, searchFolderClass, searchFolderDocuments, setFolderAcl, updateFolder
-
Methods inherited from class com.saperion.connector.rmi.AbstractRMIClientCommand
getRemoteCommand, init, reLogon, reLogonAfterConnectionFailure
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.saperion.connector.rmi.SaRMIClientCommand
addComment, addHistory, changePassword, closeSession, deleteSetting, executeCommand, getArchivedSize, getAuthorizedUsers, getBoxCount, getBoxDefinitions, getCommandInfos, getCommandInfos, getCommentInfos, getCommitMode, getCompleteHistoryInfos, getCurrentUserRole, getDDC, getDeleteMode, getEventsEnabled, getFeatures, getFieldDescriptions, getFieldDescriptions, getFullTextFields, getHistoryInfos, getLicenseCount, getMandant, getMember, getMembers, getOutOfOffice, getParentTask, getRealDBName, getRMIVersion, getServerInfos, getSession, getSetting, getSubstitute, getSystemConnector, getSystemFiles, getSystemInfo, getSystemSetting, getTask, getTaskAuditList, getTaskList, getToken, getUserIdsForQuery, getUsers, getUserSetting, getWorkflowDefinitions, invoke, isAlive, isRevisionEnabled, listActiveSessions, loadDDCNames, loadFolderDDCNames, loadSettings, loadSystemFile, loadWorkflowDDCName, logoff, logon, logon, logon, newInvoke, resolveLatestHdoc, searchSettings, sendBarcode, setEventsEnabled, setLocale, setOutOfOffice, setSetting, setSubstitute, setUsedLicense, setUserSetting, storeSystemFile
-
-
-
-
Method Detail
-
getIdsFromQuery
public java.util.List<java.lang.String> getIdsFromQuery(java.lang.String query) throws SaSystemException, SaAuthenticationException
Executes a HQL query and returns the results as a string list. Currently are only two queries in focus:
- search for hDocs
- search for sysRowIds
- Parameters:
query
- HQL query- Returns:
- String result list
- Throws:
SaSystemException
- Error on the saperion systemSaAuthenticationException
- SaAuthenticationException- See Also:
SaRMIClientCommand.getIdsFromQuery(java.lang.String)
-
getStringQueryResult
public java.util.List<SaDocumentInfo> getStringQueryResult(SaQueryInfo hqlQuery) throws SaSystemException, SaAuthenticationException, SaDBException
Executes a given HQL string and returns the results as list.- Parameters:
hqlQuery
- HQL query info- Returns:
- Result list
- Throws:
SaSystemException
- Error on the saperion systemSaAuthenticationException
- SaAuthenticationExceptionSaDBException
- query execution exception- See Also:
SaRMIClientCommand.getStringQueryResult(com.saperion.rmi.SaQueryInfo)
-
readDocumentMetadata
public SaPropertyValue[] readDocumentMetadata(java.lang.String sysRowId, java.lang.String ddcName, java.lang.String[] fields) throws SaSystemException, SaAuthenticationException, SaGetNodeException
Reads the meta data of the document with the given ID.- Parameters:
sysRowId
- The ID of the document (SYSROWID)ddcName
- The name of the database definitionfields
- Field names to be read. If empty or null, all fields will be read.- Returns:
- The Meta data of the document represented as an array of
SaPropertyValue
instances. - Throws:
SaSystemException
- SaRMICommandExceptionSaAuthenticationException
- SaAuthenticationExceptionSaGetNodeException
- SaGetNodeException- See Also:
SaRMIClientCommand.readDocumentMetadata( java.lang.String, java.lang.String, java.lang.String[])
-
getFulltext
public java.lang.String getFulltext(java.lang.String ddcName, java.lang.String sysRowId, java.lang.String hdoc, java.lang.String fieldName, long length) throws SaSystemException, SaAuthenticationException
Reads the fulltext information for the given document with the given SYSROWID in the given DDC.- Parameters:
ddcName
- DDC name of the documentsysRowId
- SYSROWID of the document. Can be null if hdoc is set. If both hdoc and sysRowId are set, hdoc will be used.hdoc
- HDOC of the document. Can be null if sysRowId is set. If both hdoc and sysRowId are set, hdoc will be used.fieldName
- name of the fulltext field to retrieve content from. If not set, the first fulltext field of the DDC will be usedlength
- maximum length of content to retrieve. If -1, the complete content will be returned.- Returns:
- Content of the fulltext for this document
- Throws:
SaSystemException
- SaSystemExceptionSaAuthenticationException
- SaAuthenticationException- See Also:
SaRMIClientCommand.getFulltext(String, String, String, String, long)
-
getVersionList
public java.util.List<java.lang.String> getVersionList(java.lang.String ddcName, java.lang.String sysrowID) throws SaSystemException, SaAuthenticationException
Reads the versionlist for the given document.- Parameters:
ddcName
- DDC namesysrowID
- SYSROWID- Returns:
- List of HDOC's
- Throws:
SaSystemException
- SaRMICommandExceptionSaAuthenticationException
- SaAuthenticationException- See Also:
SaRMIClientCommand.getVersionList(java.lang.String, java.lang.String)
-
getHDocForSysRowId
public java.lang.String getHDocForSysRowId(java.lang.String sysRowId, java.lang.String ddcName) throws SaSystemException, SaAuthenticationException, SaDDCException
Searchs the HDOC for the given SysRowId.- Parameters:
sysRowId
- SysRowIdddcName
- DDC name- Returns:
- Resultset for HDOC's
- Throws:
SaSystemException
- SaRMICommandExceptionSaAuthenticationException
- SaAuthenticationExceptionSaDDCException
- SaDDCException- See Also:
SaRMIClientCommand.getHDocForSysRowId(java.lang.String, java.lang.String)
-
startSQLTransaction
public void startSQLTransaction(java.lang.String ddcName) throws SaSystemException
Start SQL transaction.- Parameters:
ddcName
- the name of the ddc- Throws:
SaSystemException
- Error on the saperion system- See Also:
SaRMIClientCommand.startSQLTransaction(java.lang.String)
-
finishSQLTransaction
public void finishSQLTransaction(boolean commit, java.lang.String ddcName) throws SaSystemException
Finish SQL transaction.- Parameters:
commit
- True, if commit, else rollbackddcName
- the name of the ddc- Throws:
SaSystemException
- Error on the saperion system- See Also:
SaRMIClientCommand.finishSQLTransaction(boolean, java.lang.String)
-
-