| java.lang.Object org.mule.transport.file.ExpressionFilenameParser
ExpressionFilenameParser | public class ExpressionFilenameParser implements FilenameParser(Code) | | ExpressionFilenameParser can use any expression language supported by Mule
to construct a file name for the current message. Expressions can be xpath, xquery, ognl, mvel, header, function
and more. For more information see http://muledocs.org/v2/Expressions.
For example an xpath expression can be defined to pull a message id out of an xml message and use that as the file name -
${xpath:/message/header/@id}
This parser superseeds the
org.mule.transport.file.SimpleFilenameParser which has been kept in Mule 2 for
compatibility. The following demonstrates how to achieve the same results when using the ExpressionFilenameParser
over the
org.mule.transport.file.SimpleFilenameParser .
- ${DATE} : ${function:dateStamp}
- ${DATE:yy-MM-dd} : ${function:dateStamp(yy-MM-dd)}
- ${SYSTIME} : ${function:systime}
- ${UUID} : ${function:uuid}
- ${ORIGINALNAME} : ${header:originalFilename}
- ${COUNT} : ${function:counter} - note that this is a global counter. If you want a local counter per file connector then you should use the
org.mule.transport.file.SimpleFilenameParser .
- ${} : ${header:}
|
DEFAULT_DATE_FORMAT | final public static String DEFAULT_DATE_FORMAT(Code) | | |
DEFAULT_EXPRESSION | final public static String DEFAULT_EXPRESSION(Code) | | |
|
|