次の方法で共有


unicode_codepoints_from_string()

入力文字列の Unicode コードポイントの動的配列を返します。 この関数は関数の逆演算 unicode_codepoints_to_string() です。

非推奨のエイリアス: to_utf8()

構文

unicode_codepoints_from_string(unicode_codepoints_from_string()

構文規則について詳しく知る。

パラメーター

名前 必須 説明
value string ✔️ 変換するソース文字列。

戻り値

この関数に指定された文字列を構成する文字の Unicode コードポイントの動的配列を返します。 unicode_codepoints_to_string() を参照してください)

print arr = unicode_codepoints_from_string("⒦⒰⒮⒯⒪")

出力

arr
[9382, 9392, 9390, 9391, 9386]
print arr = unicode_codepoints_from_string("קוסטו - Kusto")

出力

arr
[1511, 1493, 1505, 1496, 1493, 32, 45, 32, 75, 117, 115, 116, 111]
print str = unicode_codepoints_to_string(unicode_codepoints_from_string("Kusto"))

出力

str
Kusto