class KeyCase extends ArrayMutator (View source)

Changes key casing of an array.

Traits

Properties

protected $casing from  TakesOnlyStringCasing

Methods

__construct(StringCase|string $casing)

No description

mixed
__invoke(mixed $value)

Mutate the input value.

from  Mutator
ada()

Use the Ada casing.

camel()

Use the Camel casing.

cobol()

Use the Cobol casing.

dot()

Use the Dot casing.

kebab()

Use the Kebab casing.

lower()

Use the Lower casing.

macro()

Use the Macro casing.

make(StringCase|string $casing)

No description

mixed
mutate(mixed $value)

Mutate the input value.

array
mutateArray(array $array)

No description

pascal()

Use the Pascal casing.

sentence()

Use the Sentence casing.

snake()

Use the Snake casing.

title()

Use the Title casing.

train()

Use the Train casing.

upper()

Use the Upper casing.

Details

__construct(StringCase|string $casing)

No description

Parameters

StringCase|string $casing

The casing to use

final mixed __invoke(mixed $value)

Mutate the input value.

Parameters

mixed $value

Return Value

mixed

static TakesOnlyStringCasing ada()

Use the Ada casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing camel()

Use the Camel casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing cobol()

Use the Cobol casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing dot()

Use the Dot casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing kebab()

Use the Kebab casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing lower()

Use the Lower casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing macro()

Use the Macro casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing make(StringCase|string $casing)

No description

Parameters

StringCase|string $casing

The casing to use

Return Value

TakesOnlyStringCasing

mixed mutate(mixed $value)

Mutate the input value.

Parameters

mixed $value

Return Value

mixed

protected array mutateArray(array $array)

No description

Parameters

array $array

Return Value

array

static TakesOnlyStringCasing pascal()

Use the Pascal casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing sentence()

Use the Sentence casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing snake()

Use the Snake casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing title()

Use the Title casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing train()

Use the Train casing.

Return Value

TakesOnlyStringCasing

static TakesOnlyStringCasing upper()

Use the Upper casing.

Return Value

TakesOnlyStringCasing