CharacterSet class | charset.h[22]

The CharacterSet intrinsic class provides information on character set translations and can be used to translate between the Unicode character set that the T3 VM uses internally for string values and the local character set or sets used for display, keyboard input, and file I/O.

`intrinsic class CharacterSet : Object`

Superclass Tree (in declaration order)

`CharacterSet`
`Object`

Subclass Tree

(none)

Global Objects

(none)

Summary of Properties

``

``

(none)

Summary of Methods

`getName isMappable isMappingKnown isRoundTripMappable`

Inherited from `Object` :
`callInherited cf checkDisplay createIterator createLiveIterator display displayAlt forEach getPropList getPropParams getSuperclassList isClass isTransient mapAll ofKind propDefined propInherited propType valToSymbol`

Properties

(none)

Methods

`getName ( )` | `charset.h[56]`

Get the name of the character set. This simply returns the name that was given to construct the character set.

`isMappable (val)` | `charset.h[76]`

Determine if a character or string of characters is mappable to this character set. If the input is an integer, it represents the Unicode character code for a single character; if the input is a string, each character in the string is checked. This returns true if every character given has a valid mapping in the local character set, nil if not. Note that if a string is given, and even one character is not mappable, this returns nil.

`isMappingKnown ( )` | `charset.h[65]`

Determine if the mapping is known. This returns true if the character set has a known local mapping, nil if not. Note that it doesn't matter whether or not the character set is actually in use on the local platform; all that matters is that a T3 mapping file is available on this machine.

`isRoundTripMappable (val)` | `charset.h[93]`

Determine if a character or string of characters is "round-trip" mappable to this character set. If the input is an integer, it represents a Unicode character code to be tested; if the input is a string, each character in the string is tested. Returns true if every character given has a valid round-trip mapping, nil if not.

A character has a round-trip mapping if it can be mapped to this local character set and then back to Unicode to yield the original character. If a character has a round-trip mapping, then in general the character has an exact representation in the local character set (as opposed to an approximation: if 'a-umlaut' maps to a simple unaccented 'a', or to 'ae', then it has only an approximated representation).

Adv3Lite Library Reference Manual
Generated on 08/12/2025 from adv3Lite version 2.2.2