Package org.kuali.rice.krad.service.impl
Class AttachmentServiceImpl
java.lang.Object
org.kuali.rice.krad.service.impl.AttachmentServiceImpl
- All Implemented Interfaces:
AttachmentService
- Direct Known Subclasses:
S3AttachmentServiceImpl
Attachment service implementation
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.kuali.rice.krad.data.DataObjectServiceprotected org.kuali.rice.core.api.config.property.ConfigurationService -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateAttachment(org.kuali.rice.core.api.mo.common.GloballyUnique parent, String uploadedFileName, String mimeType, int fileSize, InputStream fileContents, String attachmentTypeCode) voiddeleteAttachmentContents(Attachment attachment) voiddeletePendingAttachmentsModifiedBefore(long modificationTime) getAttachmentByNoteId(Long noteId) Retrieves an Attachment by note identifier.protected StringgetDocumentDirectory(String objectId) org.kuali.rice.core.api.config.property.ConfigurationServiceGets the configService attribute.protected voidmoveAttachmentFromPending(Attachment attachment, String objectId) voidretrieveAttachmentContents(Attachment attachment) /* (non-Javadoc)voidsetDataObjectService(org.kuali.rice.krad.data.DataObjectService dataObjectService) voidsetKualiConfigurationService(org.kuali.rice.core.api.config.property.ConfigurationService configService) Sets the configService attribute value.protected voidwriteInputStreamToFileStorage(InputStream fileContents, String fullPathUniqueFileName)
-
Field Details
-
kualiConfigurationService
protected org.kuali.rice.core.api.config.property.ConfigurationService kualiConfigurationService -
dataObjectService
protected org.kuali.rice.krad.data.DataObjectService dataObjectService
-
-
Constructor Details
-
AttachmentServiceImpl
public AttachmentServiceImpl()
-
-
Method Details
-
getAttachmentByNoteId
Retrieves an Attachment by note identifier.- Specified by:
getAttachmentByNoteIdin interfaceAttachmentService- See Also:
-
createAttachment
public Attachment createAttachment(org.kuali.rice.core.api.mo.common.GloballyUnique parent, String uploadedFileName, String mimeType, int fileSize, InputStream fileContents, String attachmentTypeCode) throws IOException - Specified by:
createAttachmentin interfaceAttachmentService- Throws:
IOException- See Also:
-
writeInputStreamToFileStorage
protected void writeInputStreamToFileStorage(InputStream fileContents, String fullPathUniqueFileName) throws IOException - Throws:
IOException
-
moveAttachmentWherePending
- Specified by:
moveAttachmentWherePendingin interfaceAttachmentService
-
moveAttachmentFromPending
- Throws:
IOException
-
deleteAttachmentContents
- Specified by:
deleteAttachmentContentsin interfaceAttachmentService
-
getDocumentDirectory
-
retrieveAttachmentContents
/* (non-Javadoc)- Specified by:
retrieveAttachmentContentsin interfaceAttachmentService- Throws:
IOException- See Also:
-
deletePendingAttachmentsModifiedBefore
public void deletePendingAttachmentsModifiedBefore(long modificationTime) - Specified by:
deletePendingAttachmentsModifiedBeforein interfaceAttachmentService- See Also:
-
getKualiConfigurationService
public org.kuali.rice.core.api.config.property.ConfigurationService getKualiConfigurationService()Gets the configService attribute.- Returns:
- Returns the configService.
-
setKualiConfigurationService
public void setKualiConfigurationService(org.kuali.rice.core.api.config.property.ConfigurationService configService) Sets the configService attribute value.- Parameters:
configService- The configService to set.
-
setDataObjectService
public void setDataObjectService(org.kuali.rice.krad.data.DataObjectService dataObjectService)
-