Lines Matching defs:characters
26 $rawCharacters = file_get_contents(__DIR__.'/../data/characters.json');
28 throw new \RuntimeException('Unable to load characters.json');
82 $characters = mb_str_split($token, 1, 'UTF-8');
85 foreach ($characters as $char) {
112 private function characterToUnicode(string $characters): int
114 $firstCharacterCode = ord($characters[0]);
121 return ($firstCharacterCode - 192) * 64 + (ord($characters[1]) - 128);
125 return ($firstCharacterCode - 224) * 4096 + (ord($characters[1]) - 128) * 64 + (ord($characters[2]) - 128);
129 return ($firstCharacterCode - 240) * 262144 + (ord($characters[1]) - 128) * 4096 + (ord($characters[2]) - 128) * 64 + (ord($characters[3]) - 128);
133 return ($firstCharacterCode - 248) * 16_777_216 + (ord($characters[1]) - 128) * 262144 + (ord($characters[2]) - 128) * 4096 + (ord($characters[3]) - 128) * 64 + (ord($characters[4]) - 128);
137 return ($firstCharacterCode - 252) * 1_073_741_824 + (ord($characters[1]) - 128) * 16_777_216 + (ord($characters[2]) - 128) * 262144 + (ord($characters[3]) - 128) * 4096 + (ord($characters[4]) - 128) * 64 + (ord($characters[5]) - 128);