Interface DataHandlerExt
public interface DataHandlerExt
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Deprecated.void
This method will give users an option to trigger a purge on temporary attachment files.readOnce()
Get anInputStream
that consumes the content of this data handler.
-
Method Details
-
readOnce
Get anInputStream
that consumes the content of this data handler. This method is similar toDataHandler.getInputStream()
except that it can be invoked only once. If the content has not been buffered yet, then the implementation may choose to enable streaming of the content.The implementation ensures that after the returned input steam is consumed, the data handler will be in the same state as after a call to
purgeDataSource()
.- Returns:
- the stream representing the content; never
null
- Throws:
IOException
- if an error occurs
-
purgeDataSource
This method will give users an option to trigger a purge on temporary attachment files. Temp files are created for attachment data that is greater than a threshold limit. On client side These temp attachment files are not deleted untilthe virtual machine exits as user can choose to read this dataHandler. So if user is not going to use the data handlers provided on this temproray files they can choose to purge the file.- Throws:
IOException
-
deleteWhenReadOnce
Deprecated.UsereadOnce()
orpurgeDataSource()
instead.- Throws:
IOException
-
readOnce()
orpurgeDataSource()
instead.