PHP 클래스 Kint

파일 보기 프로젝트 열기: raveren/kint 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$aliases
$appRootDirs
$charEncodings
$cliColors
$cliDetection
$displayCalledFrom
$expandedByDefault
$fileLinkFormat
$maxLevels
$maxStrLength
$returnOutput # stores mode and active statuses
$theme

공개 메소드들

메소드 설명
dump ( mixed $data = null ) : void | string Dump information about variables, accepts any number of parameters, supports modifiers:
enabled ( mixed $forceMode = null ) : mixed Enables or disables Kint, can globally enforce the rendering mode. If called without parameters, returns the current mode.
getIdeLink ( $file, $line )
shortenPath ( string $file ) : string generic path display callback, can be configured in the settings; purpose is to show relevant path info and hide as much of the path as possible.
trace ( array $trace = null ) : mixed Prints a debug backtrace, same as Kint::dump(1)

비공개 메소드들

메소드 설명
_getCalleeInfo ( array $trace ) : array( returns parameter names that the function was passed, as well as any predefined symbols before function call (modifiers)
_parseTrace ( array $data )
_removeAllButCode ( string $source ) : string removes comments and zaps whitespace &
_showSource ( string $file, integer $lineNumber, integer $padding = 7 ) : boolean | string trace helper, shows the place in code inline
_stepIsInternal ( $step ) : array returns whether current trace step belongs to Kint or its wrappers

메소드 상세

dump() 공개 정적인 메소드

clean up any output before kint and place the dump at the top of page: - Kint::dump() ***** expand all nodes on display: ! Kint::dump() ***** dump variables disregarding their depth: + Kint::dump() ***** return output instead of displaying it: @ Kint::dump() ***** force output as plain text ~ Kint::dump() Modifiers are supported by all dump wrapper functions, including Kint::trace(). Space is optional. You can also use the following shorthand to display debug_backtrace(): Kint::dump( 1 ); Passing the result from debug_backtrace() to kint::dump() as a single parameter will display it as trace too: $trace = debug_backtrace( true ); Kint::dump( $trace ); Or simply: Kint::dump( debug_backtrace() );
public static dump ( mixed $data = null ) : void | string
$data mixed
리턴 void | string

enabled() 공개 정적인 메소드

Enables or disables Kint, can globally enforce the rendering mode. If called without parameters, returns the current mode.
public static enabled ( mixed $forceMode = null ) : mixed
$forceMode mixed null or void - return current mode false - disable (no output) true - enable and detect cli automatically Kint::MODE_* - enable and force selected mode disregarding detection and function shorthand (s()/d()), note that you can still override this with the "~" modifier
리턴 mixed previously set value if a new one is passed

shortenPath() 공개 정적인 메소드

generic path display callback, can be configured in the settings; purpose is to show relevant path info and hide as much of the path as possible.
public static shortenPath ( string $file ) : string
$file string
리턴 string

trace() 공개 정적인 메소드

Prints a debug backtrace, same as Kint::dump(1)
public static trace ( array $trace = null ) : mixed
$trace array [OPTIONAL] you can pass your own trace, otherwise, `debug_backtrace` will be called
리턴 mixed

프로퍼티 상세

$aliases 공개적으로 정적으로 프로퍼티

public static $aliases

$appRootDirs 공개적으로 정적으로 프로퍼티

public static $appRootDirs

$charEncodings 공개적으로 정적으로 프로퍼티

public static $charEncodings

$cliColors 공개적으로 정적으로 프로퍼티

public static $cliColors

$cliDetection 공개적으로 정적으로 프로퍼티

public static $cliDetection

$displayCalledFrom 공개적으로 정적으로 프로퍼티

public static $displayCalledFrom

$expandedByDefault 공개적으로 정적으로 프로퍼티

public static $expandedByDefault

$fileLinkFormat 공개적으로 정적으로 프로퍼티

public static $fileLinkFormat

$maxLevels 공개적으로 정적으로 프로퍼티

public static $maxLevels

$maxStrLength 공개적으로 정적으로 프로퍼티

public static $maxStrLength

$returnOutput 공개적으로 정적으로 프로퍼티

# stores mode and active statuses
public static $returnOutput

$theme 공개적으로 정적으로 프로퍼티

public static $theme