PHP Class ConsoleKit\Widgets\Checklist

$checklist = new ConsoleKit\Widgets\Checklist($console); $checklist->run(array( 'Creating directory structure' => function() { code return $success; // bool }, 'Downloading scripts' => function() { code return $success; // bool } )); Will print: Creating directory structure OK Downloading scripts OK
Inheritance: extends AbstractWidget
Exibir arquivo Open project: maximebf/consolekit Class Usage Examples

Protected Properties

Property Type Description
$errorColor
$errorText
$maxMessageLength
$successColor
$successText

Public Methods

Method Description
getMaxMessageLength ( )
run ( array $steps )
runArray ( $array, $message, $callback, $useKeyInMessage = false )
setErrorText ( $text, $color = Colors::RED )
setMaxMessageLength ( $length )
setSuccessText ( $text, $color = Colors::GREEN )
step ( $message, $callback, $maxMessageLength = null )

Method Details

getMaxMessageLength() public method

public getMaxMessageLength ( )

run() public method

public run ( array $steps )
$steps array

runArray() public method

public runArray ( $array, $message, $callback, $useKeyInMessage = false )

setErrorText() public method

public setErrorText ( $text, $color = Colors::RED )

setMaxMessageLength() public method

public setMaxMessageLength ( $length )

setSuccessText() public method

public setSuccessText ( $text, $color = Colors::GREEN )

step() public method

public step ( $message, $callback, $maxMessageLength = null )

Property Details

$errorColor protected_oe property

protected $errorColor

$errorText protected_oe property

protected $errorText

$maxMessageLength protected_oe property

protected $maxMessageLength

$successColor protected_oe property

protected $successColor

$successText protected_oe property

protected $successText