public class DbNoteModule extends Object implements NoteModule
| Constructor and Description |
|---|
DbNoteModule() |
| Modifier and Type | Method and Description |
|---|---|
Note |
add(String token,
String nodeId,
String text)
Add a note to a document
|
void |
delete(String token,
String noteId)
Remove a note from a document
|
Note |
get(String token,
String noteId)
Get note from document
|
List<Note> |
list(String token,
String nodeId)
Retrieve a list of notes from a document.
|
String |
set(String token,
String noteId,
String text)
Set a new text to document note.
|
public Note add(String token, String nodeId, String text) throws LockException, PathNotFoundException, AccessDeniedException, RepositoryException, DatabaseException
NoteModuleadd in interface NoteModuletoken - The session authorization token.nodeId - The path that identifies an unique document.text - The message textLockException - A locked document can't be modified.PathNotFoundException - If there is no document in the repository with this path.AccessDeniedException - If there is any security problem:
you can't access this document because of lack of permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic void delete(String token, String noteId) throws LockException, PathNotFoundException, AccessDeniedException, RepositoryException, DatabaseException
NoteModuledelete in interface NoteModuletoken - The session authorization token.noteId - The path that identifies an unique document note.LockException - A locked document can't be modified.PathNotFoundException - If there is no document in the repository with this path.AccessDeniedException - If there is any security problem:
you can't access this document because of lack of permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic Note get(String token, String noteId) throws LockException, PathNotFoundException, AccessDeniedException, RepositoryException, DatabaseException
NoteModuleget in interface NoteModuletoken - The session authorization token.noteId - The path that identifies an unique document note.LockException - A locked document can't be modified.PathNotFoundException - If there is no document in the repository with this path.AccessDeniedException - If there is any security problem:
you can't access this document because of lack of permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic String set(String token, String noteId, String text) throws LockException, PathNotFoundException, AccessDeniedException, RepositoryException, DatabaseException
NoteModuleset in interface NoteModuletoken - The session authorization token.noteId - The path that identifies an unique document note.text - The message textLockException - A locked document can't be modified.PathNotFoundException - If there is no document in the repository with this path.AccessDeniedException - If there is any security problem:
you can't access this document because of lack of permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic List<Note> list(String token, String nodeId) throws AccessDeniedException, PathNotFoundException, RepositoryException, DatabaseException
NoteModulelist in interface NoteModuletoken - The session authorization token.nodeId - The path that identifies an unique document.PathNotFoundException - If there is no document in this repository path.RepositoryException - If there is any general repository problem.AccessDeniedExceptionDatabaseExceptionCopyright © 2016. All rights reserved.