Utility Methods
The table lists the methods for the Util class.
Util Class
| Method | Return Value | Description |
|---|---|---|
bpm.forms.Util.checkDateFormat (String value)
|
Boolean | Checks whether the date passed as a string is in the forms date edit format (that is, ISO-8601 date format) or not.
It returns
|
bpm.forms.Util.checkDateTimeFormat (String value)
|
Boolean | Checks whether the date-time passed as a string is in the forms date-time edit format (that is, ISO-8601 date-time format) or not.
Returns
|
bpm.forms.Util.checkInteger(String value)
|
Boolean | Checks whether the specified value is a valid integer or not.
Returns
|
bpm.forms.Util.checkLowerLimit (String value, String lowerLimit, Boolean lowerLimitInclusive)
|
Boolean | Checks whether the
value is numerically greater than
lowerLimit, or if
lowerLimitInclusive is
true, greater than or equal to
lowerLimit.
Returns
|
bpm.forms.Util.checkMultiplicity (Object value, Integer lowerBound, Integer upperBound)
|
Boolean | Checks whether a multi-valued object (array or list) has at least
lowerBound and at most
upperBound elements.
Returns
|
bpm.forms.Util.checkNumberConstraint (Object value, Integer totalLength, Integer decimalLength)
|
Boolean | Validates whether the
value parameter has no more than
totalLength digits and at most
decimalLength digits following the decimal place.
Returns
|
bpm.forms.Util.checkNumeric(String value)
|
Boolean | Checks whether the specified value is a valid number or not.
Returns
|
bpm.forms.Util.checkRegExp(String value, RegExp regExp)
|
Boolean | Validates a
value against a regular expression.
Returns
|
bpm.forms.Util.checkTextLength (String value, Integer length)
|
Boolean | Checks whether the specified
value conforms to the given
length constraint.
Returns
|
bpm.forms.Util.checkTimeFormat (String value)
|
Boolean | Checks whether the time passed as a string is in the forms time edit format (that is, ISO-8601 time format) or not.
Returns
|
bpm.forms.Util.checkUpperLimit (String value, String upperLimit, Boolean upperLimitInclusive)
|
Boolean | Checks whether the value is numerically less than
upperLimit, or if
upperLimitInclusive is
true, less than or equal to
upperLimit.
Returns
|
bpm.forms.Util.compare(String value1, String value2)
|
Integer | Compares two strings lexicographically and returns an integer that represents the comparison between the values:
|
bpm.forms.Util.copy(Object arg)
|
copied object | Creates and returns a deep copy of the BOM object |
bpm.forms.Util.copyAll(List list)
|
copied list | Creates and returns a new list containing deep copies of the BOM objects in the original list |
bpm.forms.Util.escapeHtml(String text)
|
String | Escapes HTML markup in the given text value so it can safely be embedded in the browser without the content being interpreted as HTML. Returns the escaped text value as a string.
This method is for use by the custom control wrappers only and is not supported in JavaScript Editor. |
bpm.forms.Util.formatDate (String formatString, Object|String date)
|
String | Formats a date value according to the input format. Returns a formatted date value as a string.
This method is for use by the custom control wrappers only and is not supported in JavaScript Editor. |
bpm.forms.Util.formatNumber (String formatString, Number|String number)
|
String | Formats a number object according to the input value. Returns a formatted number as a string.
This method is for use by the custom control wrappers only and is not supported in JavaScript Editor. |
bpm.forms.Util.loadCSS()
|
URL | Loads the Bootstrap. |
bpm.forms.Util.substitute (String template, Object args)
|
String | Substitutes arguments into a string template. This is useful when generating markup for controls that need an initial DOM structure before being instantiated. This is common with libraries such as jQuery or YUI.
Returns a string with values substituted in the template. This method is for use by the custom control wrappers only and is not supported in JavaScript Editor. |