This is automatic generated document for things in Swow\Debug\Debugger\Debugger class
Class Debugger
Constants
public SDB = " \u2588\u2588\u2588\u2588\u2588\u2588 \u2593\u2588\u2588\u2588\u2588\u2588\u2584 \u2584\u2584\u2584\u2584\n\u2592\u2588\u2588 \u2592 \u2592\u2588\u2588\u2580 \u2588\u2588\u258c\u2593\u2588\u2588\u2588\u2588\u2588\u2584\n\u2591 \u2593\u2588\u2588\u2584 \u2591\u2588\u2588 \u2588\u258c\u2592\u2588\u2588\u2592 \u2584\u2588\u2588\n \u2592 \u2588\u2588\u2592\u2591\u2593\u2588\u2584 \u258c\u2592\u2588\u2588\u2591\u2588\u2580\n\u2592\u2588\u2588\u2588\u2588\u2588\u2588\u2592\u2592\u2591\u2592\u2588\u2588\u2588\u2588\u2593 \u2591\u2593\u2588 \u2580\u2588\u2593\n \u2591\u2592\u2593\u2592 \u2592 \u2591 \u2592\u2592\u2593 \u2592 \u2591\u2592\u2593\u2588\u2588\u2588\u2580\u2592\n \u2591\u2592 \u2591 \u2592 \u2592 \u2592\u2591\u2592 \u2591\n-------------------\nSDB (Swow Debugger)\n-------------------" protected SOURCE_FILE_CONTENT_PADDING = 4 protected SOURCE_FILE_DEFAULT_LINE_COUNT = 8 Properties
protected $breakPointHandler protected $breakPoints protected static $coroutineDebugWeakMap protected $currentCoroutine protected $currentFrameIndex protected $currentSourceFile protected $currentSourceFileLine protected $daemon protected $error protected $input protected static $instance protected $lastCommand protected $lastTraceDepth protected $output protected $reloading protected $sourcePositionHandler protected static $useMbString Methods
Static method break
public static function break ( ) : void Static method breakOn
public static function breakOn ( string $point ) : static Static method breakPointHandler
protected static function breakPointHandler ( ) : void Static method convertTraceToTable
protected static function convertTraceToTable ( array<int, array{function: (string | null), class: (string | null), args: (array<string> | null), file: (string | null), line: (int | null)}> $trace , ?int $frameIndex ) : array<array{frame: int, executing: string, source position: string}> Static method convertValueToString
protected static function convertValueToString ( mixed $value , bool $forArgs ) : string Static method getCoroutineDebugWeakMap
public static function getCoroutineDebugWeakMap ( ) : WeakMap<Coroutine, DebugContext> Static method getCoroutineTraceDiffLevel
protected static function getCoroutineTraceDiffLevel ( Coroutine $coroutine , string $name ) : int We need to subtract the number of call stack layers of the Debugger itself
Static method getDebugContextOfCoroutine
public static function getDebugContextOfCoroutine ( Coroutine $coroutine ) : DebugContext Static method getExecutingFromFrame
protected static function getExecutingFromFrame ( array{function: (string | null), class: (string | null), args: (array<string> | null)} $frame ) : string Static method getExtendedLevelOfCoroutineForExecution
protected static function getExtendedLevelOfCoroutineForExecution ( Coroutine $coroutine ) : int Static method getExtendedLevelOfCoroutineForTrace
protected static function getExtendedLevelOfCoroutineForTrace ( Coroutine $coroutine ) : int Static method getFollowingSourceFileContent
protected static function getFollowingSourceFileContent ( SplFileObject $sourceFile , int $startLine , int $lineCount , int $offset ) : array<array{line: int, content: string}> Static method getInstance
public static final function getInstance ( ) : static Static method getMaxLengthOfStringLine
protected static function getMaxLengthOfStringLine ( string $string ) : int Static method getSimpleInfoOfCoroutine
protected static function getSimpleInfoOfCoroutine ( Coroutine $coroutine , bool $whatAreYouDoing ) : array{id: int, state: string, switches: int, elapsed: string, executing: (string | null), source position: (string | null)} Returns array{id: int, state: string, switches: int, elapsed: string, executing: (string | null), source position: (string | null)}
$simpleInfo
Static method getSourceFileContentAsTable
protected static function getSourceFileContentAsTable ( string $filename , int $line , ?SplFileObject & $sourceFile , int $lineCount ) : array<array{line: (string | positive-int), content: string}> Static method getSourceFileContentByTrace
protected static function getSourceFileContentByTrace ( array<array{file: (string | null), line: (int | null)}> $trace , int $frameIndex , ?SplFileObject & $sourceFile , ?int & $sourceFileLine ) : array<array{line: string, content: string}> Static method getStateNameOfCoroutine
protected static function getStateNameOfCoroutine ( Coroutine $coroutine ) : string Static method getTraceOfCoroutine
protected static function getTraceOfCoroutine ( Coroutine $coroutine , ?int $index ) : (array<int, array{function: (string | null), class: (string | null), args: array<string>, file: (string | null), line: (int | null), type: (string | null)}> | array{function: (string | null), class: (string | null), args: array<string>, file: (string | null), line: (int | null), type: (string | null)}) Returns (array<int, array{function: (string | null), class: (string | null), args: array<string>, file: (string | null), line: (int | null), type: (string | null)}> | array{function: (string | null), class: (string | null), args: array<string>, file: (string | null), line: (int | null), type: (string | null)})
$trace
Static method hasMbString
protected static function hasMbString ( ) : bool Static method isAlone
protected static function isAlone ( ) : bool Static method runOnTTY
public static function runOnTTY ( string $keyword ) : static Static method strlen
protected static function strlen ( string $string ) : int Static method substr
protected static function substr ( string $string , int $offset , ?int $length ) : string protected static function tableFormat ( array<mixed> $table ) : string Method __construct
protected function __construct ( ) Method __destruct
public function __destruct ( ) Method addBreakPoint
public function addBreakPoint ( string $point ) : static Method callSourcePositionHandler
protected function callSourcePositionHandler ( string $sourcePosition ) : string Method checkBreakPointHandler
protected function checkBreakPointHandler ( ) : static Method checkPathMap
public function checkPathMap ( ) : static Method clear
public function clear ( ) : static Method cr
public function cr ( ) : static Method error
public function error ( string $string , bool $newline ) : static Method exception
public function exception ( string $string , bool $newline ) : static Method getCurrentCoroutine
public function getCurrentCoroutine ( ) : Coroutine Method getCurrentCoroutineTrace
protected function getCurrentCoroutineTrace ( ) : array<int, array{function: (string | null), class: (string | null), args: array<string>, file: (string | null), line: (int | null), type: (string | null)}> Returns array<int, array{function: (string | null), class: (string | null), args: array<string>, file: (string | null), line: (int | null), type: (string | null)}>
$trace
Method getCurrentFrameIndex
public function getCurrentFrameIndex ( ) : int Method getCurrentFrameIndexExtendedForExecution
public function getCurrentFrameIndexExtendedForExecution ( ) : int Method getCurrentSourceFile
public function getCurrentSourceFile ( ) : ?SplFileObject Method getCurrentSourceFileLine
public function getCurrentSourceFileLine ( ) : int Method getLastCommand
public function getLastCommand ( ) : string Method in
public function in ( bool $prefix ) : string Method lf
public function lf ( ) : static Method logo
public function logo ( ) : static Method out
public function out ( string $string , bool $newline ) : static Method run
public function run ( string $keyword ) : static Method setCurrentCoroutine
protected function setCurrentCoroutine ( Coroutine $coroutine ) : static Method setCurrentFrameIndex
protected function setCurrentFrameIndex ( int $index ) : static Method setCurrentSourceFile
public function setCurrentSourceFile ( ?SplFileObject $currentSourceFile ) : static Method setCurrentSourceFileLine
public function setCurrentSourceFileLine ( int $currentSourceFileLine ) : static Method setCursorVisibility
protected function setCursorVisibility ( bool $bool ) : static Method setLastCommand
public function setLastCommand ( string $lastCommand ) : static Method setSourcePositionHandler
public function setSourcePositionHandler ( ?callable $sourcePositionHandler ) : static Method showCoroutine
protected function showCoroutine ( Coroutine $coroutine , bool $newLine ) : static Method showCoroutines
public function showCoroutines ( Coroutine[] $coroutines ) : static Method showFollowingSourceFileContent
protected function showFollowingSourceFileContent ( int $lineCount ) : static Method showSourceFileContentByTrace
public function showSourceFileContentByTrace ( array<array{file: (string | null), line: (int | null)}> $trace , int $frameIndex , bool $following ) : static Method showTrace
protected function showTrace ( array<int, array{function: (string | null), class: (string | null), args: array<string>, file: (string | null), line: (int | null)}> $trace , ?int $frameIndex , bool $newLine ) : static Method table
public function table ( array<mixed> $table , bool $newline ) : static Method waitStoppedCoroutine
protected function waitStoppedCoroutine ( Coroutine $coroutine ) : void