Class Index | File Index

Classes


Namespace ilib.CType


Defined in: ilib-dyn-full.js.

Namespace Summary
Constructor Attributes Constructor Name and Description
 
Provides a set of static routines that return information about characters.
Method Summary
Method Attributes Method Name and Description
<static>  
ilib.CType.isAlnum(ch)
Return whether or not the first character is alphabetic or numeric.
<static>  
ilib.CType.isAlpha(ch)
Return whether or not the first character is alphabetic.
<static>  
ilib.CType.isAscii(ch)
Return whether or not the first character is in the ASCII range.
<static>  
ilib.CType.isBlank(ch)
Return whether or not the first character is a blank character.
<static>  
ilib.CType.isCntrl(ch)
Return whether or not the first character is a control character.
<static>  
ilib.CType.isDigit(ch)
Return whether or not the first character is a digit character in the Latin script.
<static>  
ilib.CType.isGraph(ch)
Return whether or not the first character is any printable character other than space.
<static>  
ilib.CType.isIdeo(ch)
Return whether or not the first character is an ideographic character.
<static>  
ilib.CType.isLower(ch)
Return whether or not the first character is lower-case.
<static>  
ilib.CType.isPrint(ch)
Return whether or not the first character is any printable character, including space.
<static>  
ilib.CType.isPunct(ch)
Return whether or not the first character is punctuation.
<static>  
ilib.CType.isScript(ch, script)
Return whether or not the first character in the given string is in the given script.
<static>  
ilib.CType.isSpace(ch)
Return whether or not the first character is a whitespace character.
<static>  
ilib.CType.isUpper(ch)
Return whether or not the first character is upper-case.
<static>  
ilib.CType.isXdigit(ch)
Return whether or not the first character is a hexadecimal digit written in the Latin script.
<static>  
ilib.CType.withinRange(ch, rangeName)
Return whether or not the first character is within the named range of Unicode characters.
Namespace Detail
ilib.CType
Provides a set of static routines that return information about characters. These routines emulate the C-library ctype functions. The characters must be encoded in utf-16, as no other charsets are currently supported. Only the first character of the given string is tested.
Method Detail
<static> {boolean} ilib.CType.isAlnum(ch)
Return whether or not the first character is alphabetic or numeric.

Depends directive: !depends ctype.isalnum.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is alphabetic or numeric

<static> {boolean} ilib.CType.isAlpha(ch)
Return whether or not the first character is alphabetic.

Depends directive: !depends ctype.isalnum.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is alphabetic.

<static> {boolean} ilib.CType.isAscii(ch)
Return whether or not the first character is in the ASCII range.

Depends directive: !depends ctype.isascii.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is in the ASCII range.

<static> {boolean} ilib.CType.isBlank(ch)
Return whether or not the first character is a blank character.

Depends directive: !depends ctype.isblank.js ie. a space or a tab.

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is a blank character.

<static> {boolean} ilib.CType.isCntrl(ch)
Return whether or not the first character is a control character.

Depends directive: !depends ctype.iscntrl.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is a control character.

<static> {boolean} ilib.CType.isDigit(ch)
Return whether or not the first character is a digit character in the Latin script.

Depends directive: !depends ctype.isdigit.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is a digit character in the Latin script.

<static> {boolean} ilib.CType.isGraph(ch)
Return whether or not the first character is any printable character other than space.

Depends directive: !depends ctype.isgraph.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is any printable character other than space.

<static> {boolean} ilib.CType.isIdeo(ch)
Return whether or not the first character is an ideographic character.

Depends directive: !depends ctype.isideo.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is an ideographic character.

<static> {boolean} ilib.CType.isLower(ch)
Return whether or not the first character is lower-case. For alphabetic characters in scripts that do not make a distinction between upper- and lower-case, this function always returns true.

Depends directive: !depends ctype.islower.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is lower-case.

<static> {boolean} ilib.CType.isPrint(ch)
Return whether or not the first character is any printable character, including space.

Depends directive: !depends ctype.isprint.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is printable.

<static> {boolean} ilib.CType.isPunct(ch)
Return whether or not the first character is punctuation.

Depends directive: !depends ctype.isprint.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is punctuation.

<static> {boolean} ilib.CType.isScript(ch, script)
Return whether or not the first character in the given string is in the given script. The script is given as the 4-letter ISO 15924 script code.

Depends directive: !depends ctype.isscript.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
{string} script
the 4-letter ISO 15924 to query against
Returns:
{boolean} true if the first character is in the given script, and false otherwise

<static> {boolean} ilib.CType.isSpace(ch)
Return whether or not the first character is a whitespace character.

Depends directive: !depends ctype.isspace.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is a whitespace character.

<static> {boolean} ilib.CType.isUpper(ch)
Return whether or not the first character is upper-case. For alphabetic characters in scripts that do not make a distinction between upper- and lower-case, this function always returns true.

Depends directive: !depends ctype.isupper.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is upper-case.

<static> {boolean} ilib.CType.isXdigit(ch)
Return whether or not the first character is a hexadecimal digit written in the Latin script. (0-9 or A-F)

Depends directive: !depends ctype.isxdigit.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
Returns:
{boolean} true if the first character is a hexadecimal digit written in the Latin script.

<static> {boolean} ilib.CType.withinRange(ch, rangeName)
Return whether or not the first character is within the named range of Unicode characters. The valid list of range names are taken from the Unicode 6.0 spec. Characters in all ranges of Unicode are supported, including those supported in Javascript via UTF-16. Currently, this method supports the following range names:

Depends directive: !depends ctype.js

Parameters:
{string|ilib.String|number} ch
character or code point to examine
{string} rangeName
the name of the range to check
Returns:
{boolean} true if the first character is within the named range

Documentation generated by JsDoc Toolkit 2.4.0 on Tue Feb 02 2016 16:00:49 GMT-0800 (PST)