Interface AuditService
- All Known Implementing Classes:
SoapAuditClient
,SoapAuditService
public interface AuditService
Web Service definition interface for Notifications and Messages
- Since:
- 6.5
- Author:
- Matteo Caruso - LogicalDOC
-
Method Summary
Modifier and TypeMethodDescriptiongetDocumentHistory
(String sid, long docId) Gets the history of a given documentgetHistory
(String sid, long folderId, String oldestDate, String[] events, Integer max) Lists all the histories in the given treegetLatestHistory
(String sid, long folderId, String oldestDate, String[] events, Integer max) Lists all the histories in the given tree but just the more recent entry for each object(document or folder)getMessages
(String sid) Lists messages routed to the current usergetSubscriptions
(String sid) Lists all the subscriptions of the current uservoid
markAsRead
(String sid, long[] ids) Marks a set of messages as read by the current usersaveDocumentHistory
(String sid, WSHistory history) Saves a document historyvoid
Subscribes the current user to notifications emitted by documents or foldersvoid
unsubscribe
(String sid, Long[] ids, String type) Unsubscribes the current user to notifications emitted by documents or folders
-
Method Details
-
subscribe
void subscribe(String sid, Long[] ids, String type, String events) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Subscribes the current user to notifications emitted by documents or folders- Parameters:
sid
- The session identifierids
- The ids of documents or folderstype
- one of Subscription.TYPE_xevents
- Optional list of event codes separated by comma- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-
unsubscribe
void unsubscribe(String sid, Long[] ids, String type) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Unsubscribes the current user to notifications emitted by documents or folders- Parameters:
sid
- The session identifierids
- The ids of documents or folderstype
- one of Subscription.TYPE_x- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-
getSubscriptions
WSSubscription[] getSubscriptions(String sid) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Lists all the subscriptions of the current user- Parameters:
sid
- identifier of the session- Returns:
- array of subscriptions
- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-
getMessages
WSMessage[] getMessages(String sid) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Lists messages routed to the current user- Parameters:
sid
- identifier of the session- Returns:
- array of messages
- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-
markAsRead
void markAsRead(String sid, long[] ids) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Marks a set of messages as read by the current user- Parameters:
sid
- identifier of the sessionids
- identifiers of messages- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-
getHistory
WSHistory[] getHistory(String sid, long folderId, String oldestDate, String[] events, Integer max) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Lists all the histories in the given tree- Parameters:
sid
- The session identifierfolderId
- The tree to inspectoldestDate
- Optional oldest date to use as filterevents
- Optional array of event codes to use as filtermax
- Optional hint on the maximum number of records for each history type(document, folder ...)- Returns:
- The list of histories
- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-
getLatestHistory
WSHistory[] getLatestHistory(String sid, long folderId, String oldestDate, String[] events, Integer max) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Lists all the histories in the given tree but just the more recent entry for each object(document or folder)- Parameters:
sid
- The session identifierfolderId
- The tree to inspectoldestDate
- Optional oldest date to use as filterevents
- Optional array of event codes to use as filtermax
- Optional hint on the maximum number of records for each history type(document, folder ...)- Returns:
- The list of histories
- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-
getDocumentHistory
WSHistory[] getDocumentHistory(String sid, long docId) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException, com.logicaldoc.core.security.authorization.PermissionException Gets the history of a given document- Parameters:
sid
- Session identifierdocId
- The document id- Returns:
- Array of history records
- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid sessioncom.logicaldoc.core.security.authorization.PermissionException
- The user does not have the required permission
-
saveDocumentHistory
WSHistory saveDocumentHistory(String sid, WSHistory history) throws com.logicaldoc.core.security.authentication.AuthenticationException, com.logicaldoc.webservice.WebserviceException, com.logicaldoc.core.PersistenceException Saves a document history- Parameters:
sid
- Session identifierhistory
- The history to save- Returns:
- The saved History
- Throws:
com.logicaldoc.core.PersistenceException
- Error in the databasecom.logicaldoc.webservice.WebserviceException
- Error in the webservicecom.logicaldoc.core.security.authentication.AuthenticationException
- Invalid session
-