utf8

사용되지 않는 항목 표시

This library provides basic support for UTF-8 encoding. This library does not provide any support for Unicode other than the handling of the encoding. Any operation that needs the meaning of a character, such as character classification, is outside its scope.

Unless stated otherwise, all functions that expect a byte position as a parameter assume that the given position is either the start of a byte sequence or one plus the length of the subject string. As in the string library, negative indices count from the end of the string.

You can find a large catalog of usable UTF-8characters here.

요약

속성

  • The pattern "[%z\x01-\x7F\xC2-\xF4][\x80-\xBF]*", which matches exactly zero or more UTF-8 byte sequence, assuming that the subject is a valid UTF-8 string.

함수

char

매개 변수

codepoints: Tuple<number>

반환

매개 변수

str: string

codepoint

매개 변수

str: string
기본값: 1
기본값: i

반환

매개 변수

기본값: 1
기본값: -1

반환

offset

매개 변수

기본값: 1

반환

graphemes

매개 변수

반환

nfcnormalize

매개 변수

str: string

반환

nfdnormalize

매개 변수

str: string

반환

속성

charpattern

The pattern "[%z\x01-\x7F\xC2-\xF4][\x80-\xBF]*", which matches exactly zero or more UTF-8 byte sequence, assuming that the subject is a valid UTF-8 string.