Package org.cyclos.impl.system
Interface TempImageServiceLocal
-
- All Superinterfaces:
BaseImageService<NewTempImageParams>,BaseImageServiceLocal<TempImage,NewTempImageParams>,Service,TempImageService
- All Known Implementing Classes:
TempImageServiceImpl
public interface TempImageServiceLocal extends TempImageService, BaseImageServiceLocal<TempImage,NewTempImageParams>
Local interface forTempImageService
-
-
Field Summary
Fields Modifier and Type Field Description static intHOURS_FOR_EXPIRATIONDefines the number of hours before a temp image is considered expiredstatic StringTEMP_OWNERIn cases such as the receive payment, it might be that a user uploads the temp image (the payee) but some other user needs to see it (the payer).
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longdeleteExpiredImages()Deletes the expired temporary images from the database and the corresponding contents from the content storage.voidmove(TempImage temp, StoredFile image)Move the content of the given temp image to a final destinationvoidpreProcess(NewTempImageParams params)Makes sure that the target in the given parameter is valid.-
Methods inherited from interface org.cyclos.services.system.BaseImageService
remove, removeAll, save, saveName
-
Methods inherited from interface org.cyclos.impl.system.BaseImageServiceLocal
find, getImageNature, readContent, readContentByKey
-
Methods inherited from interface org.cyclos.services.system.TempImageService
list
-
-
-
-
Field Detail
-
TEMP_OWNER
static final String TEMP_OWNER
In cases such as the receive payment, it might be that a user uploads the temp image (the payee) but some other user needs to see it (the payer). In such cases, this field holds theInvocationContextattribute that stores the other user.- See Also:
- Constant Field Values
-
HOURS_FOR_EXPIRATION
static final int HOURS_FOR_EXPIRATION
Defines the number of hours before a temp image is considered expired- See Also:
- Constant Field Values
-
-
Method Detail
-
deleteExpiredImages
long deleteExpiredImages()
Deletes the expired temporary images from the database and the corresponding contents from the content storage.
-
move
void move(TempImage temp, StoredFile image)
Move the content of the given temp image to a final destination
-
preProcess
void preProcess(NewTempImageParams params)
Makes sure that the target in the given parameter is valid. When the target is null, setsTempImageTarget.USER_REGISTRATIONwhen there's no custom field, orTempImageTarget.CUSTOM_VALUEwhen there is one. Also validate the user parameter, setting the default to the logged user when required.
-
-