PHP 클래스 PhpSchool\CliMenu\Terminal\UnixTerminal

저자: Michael Woodward ([email protected])
상속: implements PhpSchool\CliMenu\Terminal\TerminalInterface
파일 보기 프로젝트 열기: php-school/cli-menu

공개 메소드들

메소드 설명
__construct ( ) Initialise the terminal from resource
clean ( ) Clean the whole console without jumping the window
clear ( ) Clear the terminal window
clearLine ( ) : void Clear the current cursors line
disableCursor ( ) Disable cursor
enableCursor ( ) Enable cursor
getDetails ( ) : string Get terminal details
getHeight ( ) : integer Get the available height of the terminal
getKeyedInput ( ) : string
getWidth ( ) : integer Get the available width of the terminal
isCanonical ( ) : boolean Check if TTY is in canonical mode Assumes the terminal was never in canonical mode
isTTY ( ) : boolean Test whether terminal is valid TTY
moveCursorToColumn ( integer $column ) Move the cursor to the start of a specific column
moveCursorToRow ( integer $rowNumber ) Move the cursor to the start of a specific row
moveCursorToTop ( ) : void Move the cursor to the top left of the window
setCanonicalMode ( boolean $useCanonicalMode = true ) Toggle canonical mode on TTY
supportsColour ( ) : boolean Test whether terminal supports colour output

비공개 메소드들

메소드 설명
getOriginalConfiguration ( ) : string Get the original terminal configuration / mode

메소드 상세

__construct() 공개 메소드

Initialise the terminal from resource
public __construct ( )

clean() 공개 메소드

Clean the whole console without jumping the window
public clean ( )

clear() 공개 메소드

Clear the terminal window
public clear ( )

clearLine() 공개 메소드

Clear the current cursors line
public clearLine ( ) : void
리턴 void

disableCursor() 공개 메소드

Disable cursor
public disableCursor ( )

enableCursor() 공개 메소드

Enable cursor
public enableCursor ( )

getDetails() 공개 메소드

Get terminal details
public getDetails ( ) : string
리턴 string

getHeight() 공개 메소드

Get the available height of the terminal
public getHeight ( ) : integer
리턴 integer

getKeyedInput() 공개 메소드

public getKeyedInput ( ) : string
리턴 string

getWidth() 공개 메소드

Get the available width of the terminal
public getWidth ( ) : integer
리턴 integer

isCanonical() 공개 메소드

Check if TTY is in canonical mode Assumes the terminal was never in canonical mode
public isCanonical ( ) : boolean
리턴 boolean

isTTY() 공개 메소드

Test whether terminal is valid TTY
public isTTY ( ) : boolean
리턴 boolean

moveCursorToColumn() 공개 메소드

Move the cursor to the start of a specific column
public moveCursorToColumn ( integer $column )
$column integer

moveCursorToRow() 공개 메소드

Move the cursor to the start of a specific row
public moveCursorToRow ( integer $rowNumber )
$rowNumber integer

moveCursorToTop() 공개 메소드

Move the cursor to the top left of the window
public moveCursorToTop ( ) : void
리턴 void

setCanonicalMode() 공개 메소드

Toggle canonical mode on TTY
public setCanonicalMode ( boolean $useCanonicalMode = true )
$useCanonicalMode boolean

supportsColour() 공개 메소드

Test whether terminal supports colour output
public supportsColour ( ) : boolean
리턴 boolean