class FirstAvailable extends Minifier implements ArrayAccess

Traits

Allows an object to act as a proxy for a NormalizedCollection stored in $this->collection

Properties

string $cacheDir from  Minifier
bool $keepGoing from  Minifier
protected MinifierList $collection

Methods

string
minify(string $src)

Minify given JavaScript source

mixed
get(string $key)

Return a value from this collection

array|string
getCacheDifferentiator()

Return a value that uniquely identifies this minifier's configuration

from  Minifier
string
getFromCache(string $src)

Get the minified source from cache, or minify and cache the result

from  Minifier
mixed
__call(string $methodName, array $args)

Forward all unknown method calls to $this->collection

bool
offsetExists(string|int $offset)

No description

mixed
offsetGet(string|int $offset)

No description

void
offsetSet(mixed $offset, mixed $value) Custom offsetSet()

implementation to allow assignment with a null offset to append to the

void
offsetUnset(string|int $offset)

No description

int
count()

No description

mixed
current()

No description

int|string
key()

No description

mixed
next()

No description

void
rewind()

No description

bool
valid()

No description

mixed
add(mixed $value, null $void) Add (append)

a value to this list

array
asConfig()

No description

bool
contains(mixed $value)

Test whether a given value is present in this collection

void
delete(string $key)

Delete a value from this list and remove gaps in keys

bool
exists(string $key)

Test whether an item of given key exists

mixed
indexOf(mixed $value)

Find the index of a given value

int
normalizeKey(mixed $key)

Ensure that the key is a valid offset

normalizeValue(Minifier|string $minifier)

Normalize the value to an object

string
onDuplicate(string|null $action) Query and set the action to take when add()

is called with a key that already exists

mixed
set(string $key, mixed $value)

Set and overwrite a value in this collection

__construct()

Constructor

mixed
append(mixed $value)

Append a value to this list

void
clear()

Empty this collection

mixed
insert(int $offset, mixed $value)

Insert a value at an arbitrary 0-based position

mixed
prepend(mixed $value)

Prepend a value to this list

int
remove(mixed $value)

Remove all items matching given value

Details

at line 70
string minify(string $src)

Minify given JavaScript source

Parameters

string $src

JavaScript source

Return Value

string

Minified source

at line 46
mixed get(string $key)

Return a value from this collection

Parameters

string $key

Return Value

mixed

in Minifier at line 60
array|string getCacheDifferentiator()

Return a value that uniquely identifies this minifier's configuration

Return Value

array|string

in Minifier at line 71
protected string getFromCache(string $src)

Get the minified source from cache, or minify and cache the result

Parameters

string $src

JavaScript source

Return Value

string

Minified source

in CollectionProxy at line 36
mixed __call(string $methodName, array $args)

Forward all unknown method calls to $this->collection

Parameters

string $methodName
array $args

Return Value

mixed

at line 46
bool offsetExists(string|int $offset)

No description

Parameters

string|int $offset

Return Value

bool

at line 46
mixed offsetGet(string|int $offset)

No description

Parameters

string|int $offset

Return Value

mixed

at line 46
void offsetSet(mixed $offset, mixed $value) Custom offsetSet()

implementation to allow assignment with a null offset to append to the

Parameters

mixed $offset
mixed $value) Custom offsetSet(

Return Value

void

at line 46
void offsetUnset(string|int $offset)

No description

Parameters

string|int $offset

Return Value

void

at line 46
int count()

No description

Return Value

int

at line 46
mixed current()

No description

Return Value

mixed

at line 46
int|string key()

No description

Return Value

int|string

at line 46
mixed next()

No description

Return Value

mixed

at line 46
void rewind()

No description

Return Value

void

at line 46
bool valid()

No description

Return Value

bool

at line 46
mixed add(mixed $value, null $void) Add (append)

a value to this list

Parameters

mixed $value
null $void) Add (append

Return Value

mixed

at line 46
array asConfig()

No description

Return Value

array

at line 46
bool contains(mixed $value)

Test whether a given value is present in this collection

Parameters

mixed $value

Return Value

bool

at line 46
void delete(string $key)

Delete a value from this list and remove gaps in keys

Parameters

string $key

Return Value

void

at line 46
bool exists(string $key)

Test whether an item of given key exists

Parameters

string $key

Return Value

bool

at line 46
mixed indexOf(mixed $value)

Find the index of a given value

Parameters

mixed $value

Return Value

mixed

at line 46
int normalizeKey(mixed $key)

Ensure that the key is a valid offset

Parameters

mixed $key

Return Value

int

at line 46
Minifier normalizeValue(Minifier|string $minifier)

Normalize the value to an object

Parameters

Minifier|string $minifier

Return Value

Minifier

at line 46
string onDuplicate(string|null $action) Query and set the action to take when add()

is called with a key that already exists

Parameters

string|null $action) Query and set the action to take when add(

Return Value

string

at line 46
mixed set(string $key, mixed $value)

Set and overwrite a value in this collection

Parameters

string $key
mixed $value

Return Value

mixed

at line 58
__construct()

Constructor

at line 46
mixed append(mixed $value)

Append a value to this list

Parameters

mixed $value

Return Value

mixed

at line 46
void clear()

Empty this collection

Return Value

void

at line 46
mixed insert(int $offset, mixed $value)

Insert a value at an arbitrary 0-based position

Parameters

int $offset
mixed $value

Return Value

mixed

at line 46
mixed prepend(mixed $value)

Prepend a value to this list

Parameters

mixed $value

Return Value

mixed

at line 46
int remove(mixed $value)

Remove all items matching given value

Parameters

mixed $value

Return Value

int