trait InteractsWithDictionary (View source)

Methods

string|int|null
getDictionaryKey(mixed $attribute)

Get a dictionary key attribute - casting it to a string if necessary.

Details

protected string|int|null getDictionaryKey(mixed $attribute)

Get a dictionary key attribute - casting it to a string if necessary.

Parameters

mixed $attribute

Return Value

string|int|null

Exceptions

InvalidArgumentException