PHP Class LdapTools\Utilities\MBString

Author: Chad Sikorra ([email protected])
显示文件 Open project: ldaptools/ldaptools Class Usage Examples

Protected Properties

Property Type Description
$collator null | Collator

Public Methods

Method Description
array_change_key_case ( array $values ) : array Change the keys in an array to their lower-case values.
array_change_value_case ( array $values ) : array Change the values in an array to lower-case values.
array_search_get_value ( string $needle, array $haystack ) : string Given an array value determine if it exists in the array and return the value as it is in the array.
chr ( $int ) : string Get the character for a specific integer value.
compare ( string $value1, string $value2 ) : integer Performs a comparison between two values and returns an integer result, like strnatcmp.
ord ( $string ) : integer Get the integer value of a specific character.
str_split ( string $value ) : string[] Split a string into its individual characters and return it as an array.
strtolower ( string $value ) : string Make a string lower case.

Protected Methods

Method Description
getCollator ( ) : Collator Load and return a collator instance.
isIntlLoaded ( ) : boolean Simple check for the intl extension.
isMbstringLoaded ( ) : boolean Simple check for the mbstring extension.

Method Details

array_change_key_case() public static method

Change the keys in an array to their lower-case values.
public static array_change_key_case ( array $values ) : array
$values array
return array

array_change_value_case() public static method

Change the values in an array to lower-case values.
public static array_change_value_case ( array $values ) : array
$values array
return array

array_search_get_value() public static method

Given an array value determine if it exists in the array and return the value as it is in the array.
public static array_search_get_value ( string $needle, array $haystack ) : string
$needle string
$haystack array
return string

chr() public static method

Get the character for a specific integer value.
public static chr ( $int ) : string
$int
return string

compare() public static method

Performs a comparison between two values and returns an integer result, like strnatcmp.
public static compare ( string $value1, string $value2 ) : integer
$value1 string
$value2 string
return integer

getCollator() protected static method

Load and return a collator instance.
protected static getCollator ( ) : Collator
return Collator

isIntlLoaded() protected static method

Simple check for the intl extension.
protected static isIntlLoaded ( ) : boolean
return boolean

isMbstringLoaded() protected static method

Simple check for the mbstring extension.
protected static isMbstringLoaded ( ) : boolean
return boolean

ord() public static method

Get the integer value of a specific character.
public static ord ( $string ) : integer
$string
return integer

str_split() public static method

Split a string into its individual characters and return it as an array.
public static str_split ( string $value ) : string[]
$value string
return string[]

strtolower() public static method

Make a string lower case.
public static strtolower ( string $value ) : string
$value string
return string

Property Details

$collator protected_oe static_oe property

protected static null|Collator $collator
return null | Collator