|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.camel.component.file.GenericFile<T>
public class GenericFile<T>
Generic File. Specific implementations of a file based endpoint need to provide a File for transfer.
Constructor Summary | |
---|---|
GenericFile()
|
Method Summary | |
---|---|
void |
bindToExchange(Exchange exchange)
Bind this GenericFile to an Exchange |
void |
changeFileName(String newName)
Changes the name of this remote file. |
GenericFile<T> |
copyFrom(GenericFile<T> source)
Creates a copy based on the source |
void |
copyFromPopulateAdditional(GenericFile<T> source,
GenericFile<T> result)
Copies additional information from the source to the result. |
String |
getAbsoluteFilePath()
|
GenericFileBinding<T> |
getBinding()
|
Object |
getBody()
|
String |
getEndpointPath()
|
T |
getFile()
|
long |
getFileLength()
|
String |
getFileName()
|
String |
getFileNameOnly()
|
char |
getFileSeparator()
|
long |
getLastModified()
|
String |
getParent()
|
String |
getRelativeFilePath()
|
boolean |
isAbsolute()
|
protected boolean |
isAbsolute(String name)
|
protected String |
normalizePath(String name)
|
protected String |
normalizePathToProtocol(String path)
Fixes the path separator to be according to the protocol |
void |
populateHeaders(GenericFileMessage<T> message)
Populates the GenericFileMessage relevant headers |
void |
setAbsolute(boolean absolute)
|
void |
setAbsoluteFilePath(String absoluteFilePath)
|
void |
setBinding(GenericFileBinding<T> binding)
|
void |
setBody(Object os)
|
void |
setEndpointPath(String endpointPath)
|
void |
setFile(T file)
|
void |
setFileLength(long fileLength)
|
void |
setFileName(String fileName)
|
void |
setFileNameOnly(String fileNameOnly)
|
void |
setLastModified(long lastModified)
|
void |
setRelativeFilePath(String relativeFilePath)
|
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public GenericFile()
Method Detail |
---|
public char getFileSeparator()
public GenericFile<T> copyFrom(GenericFile<T> source)
source
- the source
public void copyFromPopulateAdditional(GenericFile<T> source, GenericFile<T> result)
source
- the sourceresult
- the resultpublic void bindToExchange(Exchange exchange)
public void populateHeaders(GenericFileMessage<T> message)
GenericFileMessage
relevant headers
message
- the message to populate with headersprotected boolean isAbsolute(String name)
protected String normalizePath(String name)
public void changeFileName(String newName)
newName
- the new namepublic String getRelativeFilePath()
public void setRelativeFilePath(String relativeFilePath)
public String getFileName()
public void setFileName(String fileName)
public long getFileLength()
public void setFileLength(long fileLength)
public long getLastModified()
public void setLastModified(long lastModified)
public T getFile()
public void setFile(T file)
public Object getBody()
public void setBody(Object os)
public String getParent()
public GenericFileBinding<T> getBinding()
public void setBinding(GenericFileBinding<T> binding)
public void setAbsoluteFilePath(String absoluteFilePath)
public String getAbsoluteFilePath()
public boolean isAbsolute()
public void setAbsolute(boolean absolute)
public String getEndpointPath()
public void setEndpointPath(String endpointPath)
public String getFileNameOnly()
public void setFileNameOnly(String fileNameOnly)
protected String normalizePathToProtocol(String path)
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |