ZooKeeper Zookeeper::setDebugLevel
(PECL zookeeper >= 0.1.0)
Zookeeper::setDebugLevel — 라이브러리의 디버깅 수준을 설정합니다.
설명
public static Zookeeper::setDebugLevel(int $logLevel
): bool
매개변수
logLevel
- ZooKeeper 로그 수준 상수입니다.
반환 값
성공하면 true
를, 실패하면 false
를 반환합니다.
오류/예외
이 메소드는 매개변수 개수 또는 유형이 잘못되었거나 디버그 수준을 설정하지 못한 경우 PHP 오류/경고를 표시합니다.
주의 버전 0.3.0부터 이 메소드는 ZookeeperException과 파생 상품을 내보냅니다.
Examples
예제 #1 Zookeeper::setDebugLevel() 예제
디버그 수준을 설정합니다.
<?php
$r = Zookeeper::setDebugLevel(Zookeeper::LOG_LEVEL_WARN);
if ($r)
echo 'SUCCESS';
else
echo 'ERR';
?>
?>
위의 예는 다음을 출력합니다.
SUCCESS