substringAfterLast

Description: Returns a portion of the Subject, starting with the character immediately after the last occurrence of the argument and extending to the end of the Subject. If the argument is not present in the Subject, the entire Subject will be returned.

Subject Type: String

Arguments:

  • value : The String to search for in the Subject

Return Type: String

Examples: If the "filename" attribute has the value "a brand new filename.txt", then the following Expressions will result in the following values:

Expression

Value

${filename:substringAfterLast('.')}

txt

${filename:substringAfterLast(' ')}

filename.txt

${filename:substringAfterLast(' n')}

ew filename.txt

${filename:substringAfterLast('missing')}

a brand new filename.txt