Package org.apache.camel.component.file
Interface GenericFileBinding<T>
-
- All Known Implementing Classes:
FileBinding,GenericFileDefaultBinding
public interface GenericFileBinding<T>Binding between the generic file and the body content.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ObjectgetBody(GenericFile<T> file)Gets the body of the filevoidloadContent(org.apache.camel.Exchange exchange, GenericFile<?> file)Ensures the content is loaded from the file into memoryvoidsetBody(GenericFile<T> file, Object body)Sets the body from the given file
-
-
-
Method Detail
-
getBody
Object getBody(GenericFile<T> file)
Gets the body of the file- Parameters:
file- the file- Returns:
- the body
-
setBody
void setBody(GenericFile<T> file, Object body)
Sets the body from the given file- Parameters:
file- the filebody- the body
-
loadContent
void loadContent(org.apache.camel.Exchange exchange, GenericFile<?> file) throws IOExceptionEnsures the content is loaded from the file into memory- Parameters:
exchange- the current exchangefile- the file- Throws:
IOException- is thrown if the content could not be loaded
-
-