\Pop\Console\InputCommand

Console input command class

Summary

Methods
Properties
Constants
setValueMode()
setValueOptional()
setValueRequired()
setValueIsArray()
setValue()
acceptsValue()
isValueOptional()
isValueRequired()
isValueArray()
getValue()
__construct()
setName()
setOverride()
setHelp()
getName()
getHelp()
isOverride()
No public properties found
No constants found
No protected methods found
$valueOptional
$valueRequired
$valueIsArray
$value
$name
$help
$override
N/A
No private methods found
No private properties found
N/A

Properties

$valueOptional

$valueOptional : boolean

Input value optional

Type

boolean

$valueRequired

$valueRequired : boolean

Input value required

Type

boolean

$valueIsArray

$valueIsArray : boolean

Input value is array

Type

boolean

$value

$value : mixed

Input value

Type

mixed

$name

$name : string

Command name

Type

string

$help

$help : string

Command help

Type

string

$override

$override : boolean

Command override flag

Type

boolean

Methods

setValueMode()

setValueMode(string  $valueMode) : \Pop\Console\Input\AbstractInput

Set if the input value is required

Parameters

string $valueMode

Returns

\Pop\Console\Input\AbstractInput

setValueOptional()

setValueOptional(boolean  $optional) : \Pop\Console\Input\AbstractInput

Set if the input value is required

Parameters

boolean $optional

Returns

\Pop\Console\Input\AbstractInput

setValueRequired()

setValueRequired(boolean  $required) : \Pop\Console\Input\AbstractInput

Set if the input value is required

Parameters

boolean $required

Returns

\Pop\Console\Input\AbstractInput

setValueIsArray()

setValueIsArray(boolean  $isArray) : \Pop\Console\Input\AbstractInput

Set if the input value is an array

Parameters

boolean $isArray

Returns

\Pop\Console\Input\AbstractInput

acceptsValue()

acceptsValue() : boolean

Determine whether the input accepts a value

Returns

boolean

isValueOptional()

isValueOptional() : boolean

Determine whether the input value is optional

Returns

boolean

isValueRequired()

isValueRequired() : boolean

Determine whether the input value is required

Returns

boolean

isValueArray()

isValueArray() : boolean

Determine whether the input value is required

Returns

boolean

getValue()

getValue() : mixed

Get the input value

Returns

mixed

__construct()

__construct(string  $name, string  $valueMode = null, boolean  $override = false) : \Pop\Console\Input\Command

Instantiate a new command object

Parameters

string $name
string $valueMode
boolean $override

Returns

\Pop\Console\Input\Command

setName()

setName(string  $name) : \Pop\Console\Input\Command

Set the command name

Parameters

string $name

Returns

\Pop\Console\Input\Command

setOverride()

setOverride(boolean  $override) : \Pop\Console\Input\Command

Set if the command is override

Parameters

boolean $override

Returns

\Pop\Console\Input\Command

setHelp()

setHelp(string  $help) : \Pop\Console\Input\Command

Set the command help

Parameters

string $help

Returns

\Pop\Console\Input\Command

getName()

getName() : string

Get the command name

Returns

string

getHelp()

getHelp() : string

Get the command help

Returns

string

isOverride()

isOverride() : boolean

Determine whether the command is override

Returns

boolean