src/Peach/Markup/NameValidator.php
private static function validateNameChar($codepoint)
    {
        // @codeCoverageIgnoreStart
        static $range = null;
        if ($range === null) {
            $first = new NameValidator_Range(0x30, 0x39); // 0-9
            $range = $first
                    ->add(0x2D, 0x2E)->add(0xB7) // "-", ".", MIDDLE DOT
                    ->add(0x0300, 0x036F)->add(0x203F, 0x2040);
        }
        // @codeCoverageIgnoreEnd
        
        return self::validateNameStartChar($codepoint) || $range->validate($codepoint);
    }
private static function validateNameChar($codepoint)
    {
        // @codeCoverageIgnoreStart
        static $range = null;
        if ($range === null) {
            $first = new NameValidator_Range(0x30, 0x39); // 0-9
            $range = $first
                    ->add(0x2D, 0x2E)->add(0xB7) // "-", ".", MIDDLE DOT
                    ->add(0x0300, 0x036F)->add(0x203F, 0x2040);
        }
        // @codeCoverageIgnoreEnd
        
        return self::validateNameStartChar($codepoint) || $range->validate($codepoint);
    }
private static function validateNameChar ( $ codepoint ) { // @codeCoverageIgnoreStart static $ range = null ; if ( $ range === null ) { $ first = new NameValidator_Range ( 0x30 , 0x39 ) ; // 0-9 $ range = $ first -> add ( 0x2D , 0x2E ) -> add ( 0xB7 ) // "-", ".", MIDDLE DOT -> add ( 0x0300 , 0x036F ) -> add ( 0x203F , 0x2040 ) ; } // @codeCoverageIgnoreEnd return self :: validateNameStartChar ( $ codepoint ) || $ range -> validate ( $ codepoint ) ; }
指定された Unicode 符号点が NameChar の範囲に適合するかどうかを調べます.

@param  int $codepoint Unicode 符号点
@return bool           引数が NameChar である場合のみ true
指定された Unicode 符号点が NameChar の範囲に適合するかどうかを調べます .