Object | +--String
| SUMMARY: Constructor | Properties | Methods | DETAIL: Constructor | Properties | Methods |
| Properties Summary | |
Object |
clip
|
<static> Object |
ANUMPATTERN
|
<static> Object |
APATTERN
|
<static> Object |
BALANCE
|
<static> Object |
EMAILPATTERN
|
<static> Object |
FILEPATTERN
|
<static> Object |
HEXPATTERN
|
<static> Object |
ISOFORMAT
|
<static> Object |
LEFT
|
<static> Object |
NULL
|
<static> Object |
NUMPATTERN
|
<static> Object |
RIGHT
|
<static> Object |
URLPATTERN
|
| Methods Summary | |
Object
|
capitalize(limit)
transforms the first n characters of a string to uppercase |
Object
|
contains(str, fromIndex)
function returns true if a string contains the string passed as argument |
Object
|
count(str)
returns the amount of occurences of one string in another |
Object
|
debase64()
returns the decoded string using the base64 algorithm |
Object
|
diff(mod, separator)
function compares a string with the one passed as argument using diff |
Object
|
embody(limit, clipping, delimiter)
breaks up a string into two parts called head and tail at the given position don't apply this to HTML, i.e. |
Object
|
enbase64()
returns the string encoded using the base64 algorithm |
Object
|
encode()
|
Object
|
encodeForm()
|
Object
|
encodeXml()
|
Object
|
endsWith(str)
function returns true if the string ends with the string passed as argument |
Object
|
entitize()
translates all characters of a string into HTML entities |
Object
|
format()
|
Object
|
group(interval, str, ignoreWhiteSpace)
function inserts a string every number of characters |
Object
|
head(limit, clipping, delimiter)
get the head of a string |
Object
|
isAlpha()
function returns true if the string contains only characters a-z |
Object
|
isAlphanumeric()
function returns true if the string contains only a-z and 0-9 (case insensitive!) |
Object
|
isDateFormat()
checks if a date format pattern is correct |
Object
|
isEmail()
returns true if the string looks like an e-mail |
Object
|
isFileName()
function checks if the string passed contains any characters that are forbidden in image- or filenames |
Object
|
isHexColor()
function checks a string for a valid color value in hexadecimal format. |
Object
|
isNumeric()
function returns true if the string contains only 0-9 |
Object
|
isUrl()
function checks if the string passed contains any characters that are forbidden in URLs and tries to create a java.net.URL from it FIXME: probably deprecated -> helma.Url |
Object
|
md5()
function calculates the md5 hash of a string |
Object
|
pad(str, len, mode)
fills a string with another string up to a desired length |
Object
|
parseJSON()
|
Object
|
repeat(multiplier)
function repeats a string passed as argument |
Object
|
startsWith(str, offset)
function returns true if the string starts with the string passed as argument |
Object
|
stripTags()
|
Object
|
tail(limit, clipping, delimiter)
get the tail of a string |
Object
|
titleize()
transforms the first n characters of each word in a string to uppercase |
Object
|
toAlphanumeric()
function cleans a string by throwing away all non-alphanumeric characters |
Object
|
toDate(format, timezone)
parse a timestamp into a date object. |
Object
|
toFileName()
function cleans the string passed as argument from any characters that are forbidden or shouldn't be used in filenames |
Object
|
toHexColor()
converts a string into a hexadecimal color representation (e.g. |
Object
|
trim()
remove leading and trailing whitespace |
Object
|
unwrap(removeTags, replacement)
replace all linebreaks and optionally all w/br tags |
<static> Object
|
compose()
create a string from a bunch of substrings |
<static> Object
|
join(str1, str2, glue)
append one string onto another and add some "glue" if none of the strings is empty or null. |
<static> Object
|
random(len, mode)
creates a random string (numbers and chars) |
<static> Object
|
Sorter(field, order)
factory to create functions for sorting objects in an array |
| Properties Detail |
Object clip
<static> Object ANUMPATTERN
<static> Object APATTERN
<static> Object BALANCE
<static> Object EMAILPATTERN
<static> Object FILEPATTERN
<static> Object HEXPATTERN
<static> Object ISOFORMAT
<static> Object LEFT
<static> Object NULL
<static> Object NUMPATTERN
<static> Object RIGHT
<static> Object URLPATTERN
| Method Detail |
Object capitalize(limit)
Number - amount of characters to transform
Object contains(str, fromIndex)
String - string to search for
Int - Position to start search
Boolean -
Object count(str)
Object debase64()
Object diff(mod, separator)
String - String to compare against String object value
String - Optional regular expression string to use for splitting. If not defined, newlines will be used.
Object embody(limit, clipping, delimiter)
Number - number of charactrers or of segments separated by the delimiter
String - pre-/suffix to be pre-/appended to shortened string
String - delimiter
Object enbase64()
Object encode()
Object encodeForm()
Object encodeXml()
Object endsWith(str)
String - string pattern to search for
Object entitize()
Object format()
Object group(interval, str, ignoreWhiteSpace)
Int - number of characters after which insertion should take place
String - string to be inserted
Boolean - definitely insert at each interval position
Object head(limit, clipping, delimiter)
Object isAlpha()
Object isAlphanumeric()
Object isDateFormat()
Object isEmail()
Object isFileName()
Object isHexColor()
Object isNumeric()
Object isUrl()
Object md5()
Object pad(str, len, mode)
String - the filling string
Number - the desired length of the resulting string
Number - the direction which the string will be padded in: -1: left 0: both (balance) 1: right (you can use the constants String.LEFT, String.BALANCE and String.RIGHT here as well.)
Object parseJSON()
Object repeat(multiplier)
Int - amount of repetitions
Object startsWith(str, offset)
String - string pattern to search for
Object stripTags()
Object tail(limit, clipping, delimiter)
Object titleize()
Object toAlphanumeric()
Object toDate(format, timezone)
String - date format to be applied
Object - Java TimeZone Object (optional)
Object toFileName()
Object toHexColor()
Object trim()
Object unwrap(removeTags, replacement)
Boolean - flag indicating if html tags should be replaced
String - replacement for the linebreaks / html tags
<static> Object compose()
String - one or more strings as arguments
<static> Object join(str1, str2, glue)
String - the first string
String - the string to be appended onto the first one
String - the "glue" to be inserted between both strings
<static> Object random(len, mode)
len - length of key
mode - determines which letters to use. null or 0 = all letters; 1 = skip 0, 1, l and o which can easily be mixed with numbers; 2 = use numbers only
<static> Object Sorter(field, order)
String - name of the field each object is compared with
Number - order (ascending or descending)
| SUMMARY: Constructor | Properties | Methods | DETAIL: Constructor | Properties | Methods |