class JString extends StringHelper

String handling class for utf-8 data Wraps the phputf8 library All functions assume the validity of utf-8 strings.

Methods

static  array
splitCamelCase( string $string)

Split a string in camel case format

static  mixed
parse_url( string $url)

Does a UTF-8 safe version of PHP parse_url function

Details

static array splitCamelCase( string $string)

Split a string in camel case format

"FooBarABCDef" becomes array("Foo", "Bar", "ABC", "Def"); "JFooBar" becomes array("J", "Foo", "Bar"); "J001FooBar002" becomes array("J001", "Foo", "Bar002"); "abcDef" becomes array("abc", "Def"); "abcdefGhiJkl" becomes array("abcdef", "GhiJkl"); "ThisIsANASAAstronaut" becomes array("This", "Is", "ANASA", "Astronaut")), "JohnFitzgeraldKennedy" becomes array("John", "FitzgeraldKennedy")),

Parameters

string $string The source string.

Return Value

array The splitted string.

static mixed parse_url( string $url)

Does a UTF-8 safe version of PHP parse_url function

Parameters

string $url URL to parse

Return Value

mixed Associative array or false if badly formed URL.