- isBlank(String) - Static method in class routines.BRules
-
isBlank: true if the string is null, the empty string, or whitespace
{talendTypes} String
{Category} BRules
{param} string("hello") input : string to be tested
{example} isBlank("hello") # false
{example} isBlank(null) # true
{example} isBlank("") # true
{example} isBlank(" ") # true
- isJSON(String) - Static method in class routines.BRules
-
isJSON: true if the passed-in string adheres to JSON format
Not supported for JDKs < 6; will throw exception
Empty expressions - {} and [] - will return true
{talendTypes} String
{Category} BRules
{param} string("{name: 'Carl', program: 'BRules'}") input: json to be tested
{example} isJSON("hello") # false
{example} isJSON("{name: 'Carl', program: 'BRules'}") # true
{example} isJSON("{}") #true
{example} isJSON(null) #false
- isPhoneNum(String, String) - Static method in class routines.BRules
-
isPhoneNum: true if valid in accordance with country specifier; uses
strict check
{talendTypes} String
{Category} BRules
{param} string("regionCode") input: The country or region code to use
{param} string("phoneNumber") input: The phone number to check
{example} isPhoneNum("US", "(301) 555-5555") # true
- isPhoneNum(String, String, boolean) - Static method in class routines.BRules
-
isPhoneNum: true if valid in accordance with country specifier and
loose flag (false for strict)
{talendTypes} String
{Category} BRules
{param} string("regionCode") input: The country or region code to use
{param} string("phoneNumber") input: The phone number to check
{param} boolean: use loose validation (true) or strict (false)
{example} isPhoneNum("US", "(301) 555-5555") # true
- isXML(String, String) - Static method in class routines.BRules
-
isXML: true if the passed-in string adheres to XML well-formedness
and the specified charset
{talendTypes} String
{Category} BRules
{param} string("hello") input: xml to be tested
{param} string("ISO8859_1") input: the charset of the xml
{example} isXML("hello", "ISO8859_1") # true
{example} isXML("hello", "ISO8859_1") # false
- isXML(String) - Static method in class routines.BRules
-
isXML: true if the passed-in string adheres to XML well-formedness
using a UTF-8 string
{talendTypes} String
{Category} BRules
{param} string("hello") input: xml to be tested
{example} isXML("hello") # true
{example} isXML("hello") # false
- listToString(List<?>) - Static method in class routines.BRules
-
Forms a comma-separated list given the input java.util.List
Handles different types
Nulls are skipped, for example [A, null, B] -> A,,B
{talendTypes} String
{Category} BRules
{param} list(inputList) input: the list to convert
- listToString(List<?>, String) - Static method in class routines.BRules
-
Forms a comma-separated list given the input java.util.List using the
specified delimeter
Handles different types
Nulls are skipped, for example [A, null, B] -> A,,B
{talendTypes} String
{Category} BRules
{param} list(inputList) input: the list to convert
{param} string(delimiter) input: delimiter to used in string separating
items
- listToString(List<?>, String, String) - Static method in class routines.BRules
-
Forms a comma-separated list given the input java.util.List
Handles different types
Nulls are skipped, for example [A, null, B] -> A,,B
{talendTypes} String
{Category} BRules
{param} list(inputList) input: the list to convert
{param} string(delimiter) input: delimiter to used in string separating
items
{param} string(escapeString) input: string to wrap each item
- p(String, String) - Static method in class routines.BRules
-
p: form an html paragraph of the specified css style from
the list of objects
null objects returns an empty list (ex, "
- pad(String) - Static method in class routines.BRules
-
Deprecated.
- pad(String, int) - Static method in class routines.BRules
-
Left pads the input string with spaces
{talendTypes} String
{Category} BRules
{param} string(stringToPad) stringToPad: string to pad
{param} int(numPadChars) numPadChars: number of padded chars
{example} pad("100",6) # "000100"
- pad(String, int, char) - Static method in class routines.BRules
-
Left pads the input string with the specified character
{talendTypes} String
{Category} BRules
{param} string(stringToPad) stringToPad: string to pad
{param} int(numPadChars) numPadChars: number of padded chars
{param} char(charToUse) charToUse: char to use as padding
{example} pad("100", 6, '0') # "000100"
- pad(Integer, int, char) - Static method in class routines.BRules
-
Left pads the input integer with the specified character
{talendTypes} String
{Category} BRules
{param} int(integerToPad) integerToPad: int to pad
{param} int(numPadChars) numPadChars: number of padded chars
{param} char(charToUse) charToUse: char to use as padding
{example} pad(100, 6, '0') # "000100"
- pad(Long, int, char) - Static method in class routines.BRules
-
Left pads the input long with the specified character
{talendTypes} String
{Category} BRules
{param} long(integerToPad) integerToPad: int to pad
{param} long(numPadChars) numPadChars: number of padded chars
{param} char(charToUse) charToUse: char to use as padding
{example} pad(100L, 6, '0') # "000100"
- padRight(String, int) - Static method in class routines.BRules
-
Right pads the input string with spaces
{talendTypes} String
{Category} BRules
{param} string(stringToPad) stringToPad: string to pad
{param} int(numPadChars) numPadChars: number of padded chars
{example} pad("100", 6) # "100 "
- padRight(String, int, char) - Static method in class routines.BRules
-
Right pads the input string with the specified character
{talendTypes} String
{Category} BRules
{param} string(stringToPad) stringToPad: string to pad
{param} int(numPadChars) numPadChars: number of padded chars
{param} char(charToUse) charToUse: char to use as padding
{example} pad("100", 6, '0') # "100000"