|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface FileUploadValidationPlugin
Represents a FileUploadValidation plugin.
A FileUploadValidation plugin is used to validate the contents of a file/image suite a given customers requirements for storing a file or image into the WCM Repository.
There are any number of validation that can be performed. Some examples include:
The plugin is registered w/ WCM by providing a plugin.xml in the JAR file including the implementation and specifying and extension provider similiar to this:
<extension
point="com.ibm.workplace.wcm.api.FileUploadValidationPlugin" id="SampleValidation">
<provider class="com.yourco.validation.SampleValidation"/>
</extension>
Each FileUploadValidation plugin must also have a constructor with no arguments
| Method Summary | |
|---|---|
java.lang.String |
getName()
Returns the name for this plugin |
boolean |
validate(java.io.InputStream inputStream,
FileUploadValidationContext context)
The FileUploadValidation Plugin should validate inputStream to determine if the file or image should be stored in the WCM repository. |
| Method Detail |
|---|
java.lang.String getName()
boolean validate(java.io.InputStream inputStream,
FileUploadValidationContext context)
throws FileUploadValidationException
inputStream - String containing the file/image bytes.context - context to be used to determine additional meta information about the file or image being saved.
FileUploadValidationException - - thrown if any errors occur processing the file/image,
or if the file fails validation and the plugin wishes to pass back information about why it failed.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||