\Less_Configurable

Configurable

Summary

Methods
Properties
Constants
setOptions()
getOption()
setOption()
No public properties found
No constants found
No protected methods found
$options
$defaultOptions
N/A
No private methods found
No private properties found
N/A

Properties

$options

$options : array

Array of options

Type

array

$defaultOptions

$defaultOptions : array

Array of default options

Type

array

Methods

setOptions()

setOptions(array|object  $options) 

Set options

If $options is an object it will be converted into an array by called it's toArray method.

Parameters

array|object $options

Throws

\Exception

getOption()

getOption(string  $name, mixed  $default = null) : mixed

Get an option value by name

If the option is empty or not set a NULL value will be returned.

Parameters

string $name
mixed $default

Default value if confiuration of $name is not present

Returns

mixed

setOption()

setOption(string  $name, mixed  $value) 

Set an option

Parameters

string $name
mixed $value