Interface DocumentService
-
- All Superinterfaces:
CRUDService<DocumentDTO,DocumentData,DocumentDataParams>,Service
- All Known Subinterfaces:
DocumentServiceLocal
- All Known Implementing Classes:
DocumentServiceImpl,DocumentServiceSecurity
public interface DocumentService extends CRUDService<DocumentDTO,DocumentData,DocumentDataParams>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description DocumentVOgetDocument(@NotNull DocumentVO document)Used to get the view only object of the documentRawFileVOgetDocumentFile(@NotNull DocumentVO document)Return the file vo for a given documentDocumentSearchDatagetDocumentSearchData(UserLocatorVO user)Returns data used to search documents, either over the given user or general documentsProcessDynamicDocumentDatagetProcessDynamicDocumentData(@NotNull DocumentVO document, UserLocatorVO locator)Returns data used to fill a dynamic document based on the given user locator dataList<DocumentVO>listUserDocuments(UserLocatorVO locator)List all documents enabled for the given userStringprocessDynamicDocument(@NotNull ProcessDynamicDocumentDTO params)Processes the given document using the given user and custom field valuesSerializableInputStreamreadContent(@NotNull DocumentVO document)Reads the contents of the documentvoidsaveFile(@NotNull DocumentVO document, String contentType, String fileName, SerializableInputStream contents)Saves the given document, returning the generated identifierLongsaveWithFile(@NotNull DocumentDTO document, String contentType, String fileName, SerializableInputStream contents)Saves the given document and filePage<DocumentVO>search(@NotNull DocumentQuery query)List all documents filtered by category-
Methods inherited from interface org.cyclos.services.CRUDService
getData, getDataForNew, load, remove, removeAll, save
-
-
-
-
Method Detail
-
getDocument
DocumentVO getDocument(@NotNull @NotNull DocumentVO document) throws FrameworkException
Used to get the view only object of the document- Throws:
FrameworkException
-
getDocumentFile
RawFileVO getDocumentFile(@NotNull @NotNull DocumentVO document) throws FrameworkException
Return the file vo for a given document- Throws:
FrameworkException
-
getDocumentSearchData
DocumentSearchData getDocumentSearchData(UserLocatorVO user) throws FrameworkException
Returns data used to search documents, either over the given user or general documents- Throws:
FrameworkException
-
getProcessDynamicDocumentData
ProcessDynamicDocumentData getProcessDynamicDocumentData(@NotNull @NotNull DocumentVO document, UserLocatorVO locator) throws FrameworkException
Returns data used to fill a dynamic document based on the given user locator data- Throws:
FrameworkException
-
listUserDocuments
List<DocumentVO> listUserDocuments(UserLocatorVO locator) throws FrameworkException
List all documents enabled for the given user- Throws:
FrameworkException
-
processDynamicDocument
String processDynamicDocument(@NotNull @NotNull ProcessDynamicDocumentDTO params) throws FrameworkException
Processes the given document using the given user and custom field values- Throws:
FrameworkException
-
readContent
SerializableInputStream readContent(@NotNull @NotNull DocumentVO document) throws FrameworkException
Reads the contents of the document- Throws:
EntityNotFoundException- When the image is not foundFrameworkException
-
saveFile
void saveFile(@NotNull @NotNull DocumentVO document, String contentType, String fileName, SerializableInputStream contents) throws FrameworkExceptionSaves the given document, returning the generated identifier- Throws:
FrameworkException
-
saveWithFile
Long saveWithFile(@NotNull @NotNull DocumentDTO document, String contentType, String fileName, SerializableInputStream contents) throws FrameworkException
Saves the given document and file- Throws:
FrameworkException
-
search
Page<DocumentVO> search(@NotNull @NotNull DocumentQuery query) throws FrameworkException
List all documents filtered by category- Throws:
FrameworkException
-
-