class · System

Unicode

public class System.Unicode : System.Any

Code points to and from UTF-8, UTF-16 and UTF-32 units (the unit type says which).

Kind
class
Namespace
System
Assembly
System.Core
Access
public, static, abstract
Source file
String.ant

Inheritance

Base classes
Any Unicode

Methods

static method Decode<T>(units: T[]) -> u32[]
#

static

The code points of units (UTF-8 for u8, UTF-16 for u16, UTF-32 for u32); malformed ones become U+FFFD.

static method EncodedLength<T>(points: u32[]) -> i32
#

static

How many units of T points take.

static method Encode<T>(points: u32[]) -> T[]
#

static

points as units of T (UTF-8, UTF-16 or UTF-32).

static method FromUtf16(units: u16[]) -> System.String<u8>
#

static

Text from UTF-16 units (what the runtime's services give): in UTF-8.

static method ToUtf16(text: System.String<u8>) -> u16[]
#

static

A str's text as UTF-16 units (what the runtime's services take).

static method ToString(point: u32) -> System.String<u8>
#

static

One code point as a str.

Inherited members (5)

Source

Unicode as Larva HIR, decompiled from its Larva HIR.

System.Unicode.hir
// Code points to and from UTF-8, UTF-16 and UTF-32 units (the unit type says which).
public class System.Unicode : System.Any
{
    // The code points of `units` (UTF-8 for u8, UTF-16 for u16, UTF-32 for u32); malformed ones become U+FFFD.
    static method Decode<T>(units: T[]) -> u32[]
    // How many units of T `points` take.
    static method EncodedLength<T>(points: u32[]) -> i32
    // `points` as units of T (UTF-8, UTF-16 or UTF-32).
    static method Encode<T>(points: u32[]) -> T[]
    // Text from UTF-16 units (what the runtime's services give): in UTF-8.
    static method FromUtf16(units: u16[]) -> System.String<u8>
    // A str's text as UTF-16 units (what the runtime's services take).
    static method ToUtf16(text: System.String<u8>) -> u16[]
    // One code point as a str.
    static method ToString(point: u32) -> System.String<u8>
}
Esc