PHP 클래스 PhpSchool\CliMenu\MenuItem\StaticItem

저자: Michael Woodward ([email protected])
상속: implements PhpSchool\CliMenu\MenuItem\MenuItemInterface
파일 보기 프로젝트 열기: php-school/cli-menu 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( string $text )
canSelect ( ) : boolean Can the item be selected
getRows ( MenuStyle $style, boolean $selected = false ) : array The output text for the item
getSelectAction ( ) : void Execute the items callable if required
getText ( ) : string Return the raw string of text
hideItemExtra ( ) Disable showing item extra
showItemExtra ( ) Enable showing item extra
showsItemExtra ( ) : boolean Whether or not the menu item is showing the menustyle extra value

메소드 상세

__construct() 공개 메소드

public __construct ( string $text )
$text string

canSelect() 공개 메소드

Can the item be selected
public canSelect ( ) : boolean
리턴 boolean

getRows() 공개 메소드

The output text for the item
public getRows ( MenuStyle $style, boolean $selected = false ) : array
$style PhpSchool\CliMenu\MenuStyle
$selected boolean
리턴 array

getSelectAction() 공개 메소드

Execute the items callable if required
public getSelectAction ( ) : void
리턴 void

getText() 공개 메소드

Return the raw string of text
public getText ( ) : string
리턴 string

hideItemExtra() 공개 메소드

Disable showing item extra
public hideItemExtra ( )

showItemExtra() 공개 메소드

Enable showing item extra
public showItemExtra ( )

showsItemExtra() 공개 메소드

Whether or not the menu item is showing the menustyle extra value
public showsItemExtra ( ) : boolean
리턴 boolean