Interface WrappedFile<T>
- Type Parameters:
T- the native file type wrapped by this instance
public interface WrappedFile<T>
Abstraction over a file-like object consumed by a file-oriented
Consumer (such as camel-file, camel-ftp, or
camel-sftp), providing uniform access to the underlying file handle, its content, and its length.
Implementations wrap different native file types (for example java.io.File for the local file system, or a
library-specific remote file object for FTP/SFTP). The body returned by getBody() may be a stream, a byte
array, or a string depending on the component configuration.- See Also:
-
Method Details
-
getFile
-
getBody
-
getFileLength
long getFileLength()Gets the file length in bytes.- Returns:
- the length of the file in bytes.
-