Package com.soffid.iam.doc.service
Class DocumentServiceBase
- java.lang.Object
-
- com.soffid.iam.doc.service.DocumentServiceBase
-
- All Implemented Interfaces:
com.soffid.iam.doc.service.DocumentService
- Direct Known Subclasses:
DocumentServiceImpl
public abstract class DocumentServiceBase extends Object implements com.soffid.iam.doc.service.DocumentService
Spring Service base class for
see com.soffid.iam.doc.service.DocumentServicecom.soffid.iam.doc.service.DocumentService, provides access to all services and entities referenced by this service.
-
-
Constructor Summary
Constructors Constructor Description DocumentServiceBase()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidaddSign(es.caib.signatura.api.Signature firma)voidcloseDocument()voidcreateDocument(String mimeType, String externalName, String application)voiddeleteDocument(com.soffid.iam.doc.api.DocumentReference reference)voidendDownloadTransfer()voidendUploadTransfer()voidexportDocuments(OutputStream out)DocSignDaogetDocSignDao()Gets reference todocSignDao.DocumentEntityDaogetDocumentEntityDao()Gets reference todocumentEntityDao.StringgetExternalName()FileSystemDaogetFileSystemDao()Gets reference tofileSystemDao.StringgetFsPath()StringgetMimeType()protected PrincipalgetPrincipal()Gets the currentprincipalif one has been set, otherwise returnsnull.com.soffid.iam.doc.api.DocumentReferencegetReference()List<es.caib.signatura.api.Signature>getSigns()protected abstract voidhandleAddSign(es.caib.signatura.api.Signature firma)protected abstract voidhandleCloseDocument()protected abstract voidhandleCreateDocument(String mimeType, String externalName, String application)protected abstract voidhandleDeleteDocument(com.soffid.iam.doc.api.DocumentReference reference)protected abstract voidhandleEndDownloadTransfer()protected abstract voidhandleEndUploadTransfer()protected abstract voidhandleExportDocuments(OutputStream out)protected abstract StringhandleGetExternalName()protected abstract StringhandleGetFsPath()protected abstract StringhandleGetMimeType()protected abstract com.soffid.iam.doc.api.DocumentReferencehandleGetReference()protected abstract List<es.caib.signatura.api.Signature>handleGetSigns()protected abstract voidhandleImportDocuments(InputStream out)protected abstract byte[]handleNextDownloadPackage(int length)protected abstract voidhandleNextUploadPackage(byte[] filePackage, int length)protected abstract voidhandleOpenDocument(com.soffid.iam.doc.api.DocumentReference reference)protected abstract voidhandleOpenDownloadTransfer()protected abstract voidhandleOpenUploadTransfer()voidimportDocuments(InputStream out)byte[]nextDownloadPackage(int length)voidnextUploadPackage(byte[] filePackage, int length)voidopenDocument(com.soffid.iam.doc.api.DocumentReference reference)voidopenDownloadTransfer()voidopenUploadTransfer()voidsetDocSignDao(DocSignDao docSignDao)Sets reference todocSignDao.voidsetDocumentEntityDao(DocumentEntityDao documentEntityDao)Sets reference todocumentEntityDao.voidsetFileSystemDao(FileSystemDao fileSystemDao)Sets reference tofileSystemDao.
-
-
-
Method Detail
-
setDocSignDao
public void setDocSignDao(DocSignDao docSignDao)
Sets reference todocSignDao.
-
getDocSignDao
public DocSignDao getDocSignDao()
Gets reference todocSignDao.
-
setDocumentEntityDao
public void setDocumentEntityDao(DocumentEntityDao documentEntityDao)
Sets reference todocumentEntityDao.
-
getDocumentEntityDao
public DocumentEntityDao getDocumentEntityDao()
Gets reference todocumentEntityDao.
-
setFileSystemDao
public void setFileSystemDao(FileSystemDao fileSystemDao)
Sets reference tofileSystemDao.
-
getFileSystemDao
public FileSystemDao getFileSystemDao()
Gets reference tofileSystemDao.
-
nextDownloadPackage
@Transactional(isolation=DEFAULT, propagation=REQUIRED, readOnly=true) public byte[] nextDownloadPackage(int length) throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.DocumentBeanException- Specified by:
nextDownloadPackagein interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.DocumentBeanException
-
handleNextDownloadPackage
protected abstract byte[] handleNextDownloadPackage(int length) throws Exception- Throws:
Exception
-
getReference
@Transactional(rollbackFor=java.lang.Exception.class) public com.soffid.iam.doc.api.DocumentReference getReference() throws es.caib.seycon.ng.exception.InternalErrorException
- Specified by:
getReferencein interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleGetReference
protected abstract com.soffid.iam.doc.api.DocumentReference handleGetReference() throws Exception- Throws:
Exception
-
getExternalName
@Transactional(rollbackFor=java.lang.Exception.class) public String getExternalName() throws es.caib.seycon.ng.exception.InternalErrorException
- Specified by:
getExternalNamein interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleGetExternalName
protected abstract String handleGetExternalName() throws Exception
- Throws:
Exception
-
getFsPath
@Transactional(rollbackFor=java.lang.Exception.class) public String getFsPath() throws es.caib.seycon.ng.exception.InternalErrorException
- Specified by:
getFsPathin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
getMimeType
@Transactional(rollbackFor=java.lang.Exception.class) public String getMimeType() throws es.caib.seycon.ng.exception.InternalErrorException
- Specified by:
getMimeTypein interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
getSigns
@Transactional(rollbackFor=java.lang.Exception.class) public List<es.caib.signatura.api.Signature> getSigns() throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.NASException
- Specified by:
getSignsin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.NASException
-
handleGetSigns
protected abstract List<es.caib.signatura.api.Signature> handleGetSigns() throws Exception
- Throws:
Exception
-
addSign
@Transactional(rollbackFor=java.lang.Exception.class) public void addSign(es.caib.signatura.api.Signature firma) throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.NASException
- Specified by:
addSignin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.NASException
-
handleAddSign
protected abstract void handleAddSign(es.caib.signatura.api.Signature firma) throws Exception- Throws:
Exception
-
closeDocument
@Transactional(isolation=DEFAULT, propagation=REQUIRES_NEW) public void closeDocument() throws es.caib.seycon.ng.exception.InternalErrorException- Specified by:
closeDocumentin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleCloseDocument
protected abstract void handleCloseDocument() throws Exception- Throws:
Exception
-
createDocument
@Transactional(isolation=DEFAULT, propagation=REQUIRES_NEW) public void createDocument(String mimeType, String externalName, String application) throws es.caib.seycon.ng.exception.InternalErrorException- Specified by:
createDocumentin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleCreateDocument
protected abstract void handleCreateDocument(String mimeType, String externalName, String application) throws Exception
- Throws:
Exception
-
deleteDocument
@Transactional(isolation=DEFAULT, propagation=REQUIRES_NEW, noRollbackFor={es.caib.seycon.ng.exception.InternalErrorException.class,com.soffid.iam.doc.exception.DocumentBeanException.class}) public void deleteDocument(com.soffid.iam.doc.api.DocumentReference reference) throws es.caib.seycon.ng.exception.InternalErrorException- Specified by:
deleteDocumentin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleDeleteDocument
protected abstract void handleDeleteDocument(com.soffid.iam.doc.api.DocumentReference reference) throws Exception- Throws:
Exception
-
endDownloadTransfer
@Transactional(isolation=DEFAULT, propagation=REQUIRED, readOnly=true) public void endDownloadTransfer() throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.DocumentBeanException- Specified by:
endDownloadTransferin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.DocumentBeanException
-
handleEndDownloadTransfer
protected abstract void handleEndDownloadTransfer() throws Exception- Throws:
Exception
-
endUploadTransfer
@Transactional(isolation=DEFAULT, propagation=REQUIRES_NEW) public void endUploadTransfer() throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.DocumentBeanException- Specified by:
endUploadTransferin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.DocumentBeanException
-
handleEndUploadTransfer
protected abstract void handleEndUploadTransfer() throws Exception- Throws:
Exception
-
exportDocuments
@Transactional(isolation=DEFAULT, propagation=NEVER, readOnly=true) public void exportDocuments(OutputStream out) throws es.caib.seycon.ng.exception.InternalErrorException- Specified by:
exportDocumentsin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleExportDocuments
protected abstract void handleExportDocuments(OutputStream out) throws Exception
- Throws:
Exception
-
importDocuments
@Transactional(isolation=DEFAULT, propagation=NEVER) public void importDocuments(InputStream out) throws es.caib.seycon.ng.exception.InternalErrorException- Specified by:
importDocumentsin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleImportDocuments
protected abstract void handleImportDocuments(InputStream out) throws Exception
- Throws:
Exception
-
nextUploadPackage
@Transactional(isolation=DEFAULT, propagation=REQUIRES_NEW) public void nextUploadPackage(byte[] filePackage, int length) throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.DocumentBeanException- Specified by:
nextUploadPackagein interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.DocumentBeanException
-
handleNextUploadPackage
protected abstract void handleNextUploadPackage(byte[] filePackage, int length) throws Exception- Throws:
Exception
-
openDocument
@Transactional(rollbackFor=java.lang.Exception.class) public void openDocument(com.soffid.iam.doc.api.DocumentReference reference) throws es.caib.seycon.ng.exception.InternalErrorException
- Specified by:
openDocumentin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorException
-
handleOpenDocument
protected abstract void handleOpenDocument(com.soffid.iam.doc.api.DocumentReference reference) throws Exception- Throws:
Exception
-
openDownloadTransfer
@Transactional(isolation=DEFAULT, propagation=REQUIRED, readOnly=true) public void openDownloadTransfer() throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.DocumentBeanException- Specified by:
openDownloadTransferin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.DocumentBeanException
-
handleOpenDownloadTransfer
protected abstract void handleOpenDownloadTransfer() throws Exception- Throws:
Exception
-
openUploadTransfer
@Transactional(isolation=DEFAULT, propagation=REQUIRES_NEW) public void openUploadTransfer() throws es.caib.seycon.ng.exception.InternalErrorException, com.soffid.iam.doc.exception.DocumentBeanException- Specified by:
openUploadTransferin interfacecom.soffid.iam.doc.service.DocumentService- Throws:
es.caib.seycon.ng.exception.InternalErrorExceptioncom.soffid.iam.doc.exception.DocumentBeanException
-
handleOpenUploadTransfer
protected abstract void handleOpenUploadTransfer() throws Exception- Throws:
Exception
-
getPrincipal
protected Principal getPrincipal()
Gets the currentprincipalif one has been set, otherwise returnsnull.- Returns:
- the current principal
-
-