class MenuList extends OptionList

Traits

Methods

int
count()

No description

create(ItemInterface ...$options)

No description

static MenuList
createFromLinks(array $linksArray)

Create MenuList from legacy link array

static MenuList
createFromRemoteURL(string|null $remoteURL)

No description

ItemInterface|null
first()

Get first element

Option|null
getFirstEnabledOption()

Returns the first option of this list, that is enabled (not disabled).

array
getItems()

No description

getIterator()

No description

Option|null
getOption($key)

No description

string|null
getRemoteURL()

No description

array
jsonSerialize()

No description

ItemInterface|null
last()

Return the last element

bool
offsetExists($offset)

No description

ItemInterface|null
offsetGet($offset)

No description

void
offsetSet($offset, $value)

No description

void
offsetUnset($offset)

No description

int
push(ItemInterface $item)

No description

static string
renderForCodeception(array $attributes = [])

No description

void
setItems(array $items)

No description

setRemoteURL(string|null $remoteURL)

No description

array
toArray()

Transforms the option into an array.

int
unshift(ItemInterface $item)

No description

Details

in ItemListTrait at line 147
int count()

No description

Return Value

int

at line 31
static ItemListInterface create(ItemInterface ...$options)

No description

Parameters

ItemInterface ...$options

Return Value

ItemListInterface

Create MenuList from legacy link array

Parameters

array $linksArray

Return Value

MenuList

at line 54
static MenuList createFromRemoteURL(string|null $remoteURL)

No description

Parameters

string|null $remoteURL

Return Value

MenuList

in ItemListTrait at line 96
ItemInterface|null first()

Get first element

Return Value

ItemInterface|null

in OptionList at line 86
Option|null getFirstEnabledOption()

Returns the first option of this list, that is enabled (not disabled).

Otherwise, returns null.

Return Value

Option|null

in ItemListTrait at line 57
array getItems()

No description

Return Value

array

in ItemListTrait at line 107
ArrayIterator getIterator()

No description

Return Value

ArrayIterator

in OptionList at line 64
Option|null getOption($key)

No description

Parameters

$key

Return Value

Option|null

at line 65
string|null getRemoteURL()

No description

Return Value

string|null

in ItemListTrait at line 154
array jsonSerialize()

No description

Return Value

array

in ItemListTrait at line 88
ItemInterface|null last()

Return the last element

Return Value

ItemInterface|null

in ItemListTrait at line 116
bool offsetExists($offset)

No description

Parameters

$offset

Return Value

bool

in ItemListTrait at line 125
ItemInterface|null offsetGet($offset)

No description

Parameters

$offset

Return Value

ItemInterface|null

in ItemListTrait at line 133
void offsetSet($offset, $value)

No description

Parameters

$offset
$value

Return Value

void

in ItemListTrait at line 140
void offsetUnset($offset)

No description

Parameters

$offset

Return Value

void

in ItemListTrait at line 44
int push(ItemInterface $item)

No description

Parameters

ItemInterface $item

Return Value

int

at line 73
static string renderForCodeception(array $attributes = [])

No description

Parameters

array $attributes

Accepts the link items

Return Value

string

HTML representation for Codeception

in ItemListTrait at line 66
void setItems(array $items)

No description

Parameters

array $items

Return Value

void

at line 60
MenuList setRemoteURL(string|null $remoteURL)

No description

Parameters

string|null $remoteURL

Return Value

MenuList

in ItemListTrait at line 74
array toArray()

Transforms the option into an array.

Return Value

array

in ItemListTrait at line 49
int unshift(ItemInterface $item)

No description

Parameters

ItemInterface $item

Return Value

int