padLeft
Description: The padLeft
function prepends the given padding string (or '_'
, if nothing is provided) to the argument String
until the passed desired length is reached.
It returns the argument as is if its length is already equal or higher than the desired length, if the padding string is null
, and if the desired length is either negative or greater than Integer.MAX_VALUE
. It returns null
if the argument string is not a valid attribute.
Subject Type: String
Arguments:
-
DesiredLength : The integer value to pad to.
-
PaddingString : The optional string to pad with.
"_"
will be used if aPaddingString
is not provided. If thePaddingString
is not an exact multiple of the actual pad size, it will be trimmed to fit inDesiredLength
.
Return Type: String
Examples: If the "greetings" attribute has the value "hello", then the following Expressions will provide the following results:
Expression |
Value |
|
|
|
|
|
|
|
|