IntlChar charDirection() 함수는 입력된 값에 대한 양방향 범주 값을 표시하는 데 사용됩니다.
구문
int IntlChar::charDirection(val)
매개변수
-
val - UTF-8 문자열로 인코딩된 정수 또는 문자.
반환
IntlChar charDirection() 함수는 다음 양방향 범주 값을 반환합니다. -
-
IntlChar::CHAR_DIRECTION_LEFT_TO_RIGHT
-
IntlChar::CHAR_DIRECTION_RIGHT_TO_LEFT
-
IntlChar::CHAR_DIRECTION_EUROPEAN_NUMBER
-
IntlChar::CHAR_DIRECTION_EUROPEAN_NUMBER_SEPARATOR
-
IntlChar::CHAR_DIRECTION_EUROPEAN_NUMBER_TERMINATOR
-
IntlChar::CHAR_DIRECTION_ARABIC_NUMBER
-
IntlChar::CHAR_DIRECTION_COMMON_NUMBER_SEPARATOR
-
IntlChar::CHAR_DIRECTION_BLOCK_SEPARATOR
-
IntlChar::CHAR_DIRECTION_SEGMENT_SEPARATOR
-
IntlChar::CHAR_DIRECTION_WHITE_SPACE_NEUTRAL
-
IntlChar::CHAR_DIRECTION_OTHER_NEUTRAL
-
IntlChar::CHAR_DIRECTION_LEFT_TO_RIGHT_EMBEDDING
-
IntlChar::CHAR_DIRECTION_LEFT_TO_RIGHT_OVERRIDE
-
IntlChar::CHAR_DIRECTION_RIGHT_TO_LEFT_ARABIC
-
IntlChar::CHAR_DIRECTION_RIGHT_TO_LEFT_EMBEDDING
-
IntlChar::CHAR_DIRECTION_RIGHT_TO_LEFT_OVERRIDE
-
IntlChar::CHAR_DIRECTION_POP_DIRECTIONAL_FORMAT
-
IntlChar::CHAR_DIRECTION_DIR_NON_SPACING_MARK
-
IntlChar::CHAR_DIRECTION_BOUNDARY_NEUTRAL
-
IntlChar::CHAR_DIRECTION_FIRST_STRONG_ISOLATE
-
IntlChar::CHAR_DIRECTION_LEFT_TO_RIGHT_ISOLATE
-
IntlChar::CHAR_DIRECTION_RIGHT_TO_LEFT_ISOLATE
-
IntlChar::CHAR_DIRECTION_POP_DIRECTIONAL_ISOLATE
-
IntlChar::CHAR_DIRECTION_CHAR_DIRECTION_COUNT
예시
다음은 예입니다 -
<?php var_dump(IntlChar::charDirection("-")); echo "<br>"; var_dump(IntlChar::charDirection("*")); echo "<br>"; var_dump(IntlChar::charDirection("kjh")); echo "<br>"; var_dump(IntlChar::charDirection("H")); echo "<br>"; ?>
출력
다음은 출력입니다 -
int(3) int(10) NULL int(0)