(PHP 7 >= 7.3, PHP 8)
Normalizer::getRawDecomposition -- normalizer_get_raw_decomposition — UTF-8 エンコードされているコードポイントから、Decomposition_Mapping プロパティの値を取得する
オブジェクト指向型
$string, int $form = Normalizer::FORM_C): ?string手続き型
指定された UTF-8 エンコードされているコードポイントから、 Unicode Character Database (UCD) で指定されている Decomposition_Mapping プロパティの値を取得します。
string入力文字列。 この値は単一の文字で、 UTF-8 エンコードされているコードポイントです。
Unicode Character Database (UCD) に存在する場合、 Decomposition_Mapping プロパティの値を含む文字列を返します。
   指定された文字に
   Decomposition_Mapping プロパティの値がない場合は、
   null を返します。
  
例1 Normalizer::getRawDecomposition() の例
<?php
$result = "";
$strings = [
    "a",
    "\u{FFDA}",
    "\u{FDFA}",
    "",
    "aa",
    "\xF5",
];
foreach ($strings as $string) {
    $decomposition = Normalizer::getRawDecomposition($string);
    // $decomposition = normalizer_get_raw_decomposition($string); Procedural way
    $error_code = intl_get_error_code();
    $error_message = intl_get_error_message();
    $string_hex = bin2hex($string);
    $result .= "---------------------\n";
    if ($decomposition === null) {
        $result .= "'$string_hex' has no decomposition mapping\n" ;
    } else {
        $result .= "'$string_hex' has the decomposition mapping '" . bin2hex($decomposition) . "'\n" ;
    }
    $result .= "error info: '$error_message' ($error_code)\n";
}
echo $result;
?>上の例の出力は以下となります。
--------------------- '61' has no decomposition mapping error info: 'U_ZERO_ERROR' (0) --------------------- 'efbf9a' has the decomposition mapping 'e385a1' error info: 'U_ZERO_ERROR' (0) --------------------- 'efb7ba' has the decomposition mapping 'd8b5d984d98920d8a7d984d984d98720d8b9d984d98ad98720d988d8b3d984d985' error info: 'U_ZERO_ERROR' (0) --------------------- '' has no decomposition mapping error info: 'Input string must be exactly one UTF-8 encoded code point long.: U_ILLEGAL_ARGUMENT_ERROR' (1) --------------------- '6161' has no decomposition mapping error info: 'Input string must be exactly one UTF-8 encoded code point long.: U_ILLEGAL_ARGUMENT_ERROR' (1) --------------------- 'f5' has no decomposition mapping error info: 'Code point out of range: U_ILLEGAL_ARGUMENT_ERROR' (1)
