Méthode | Description | |
---|---|---|
__construct ( Puli\Repository\Api\ResourceRepository $repo, array $paths ) | Creates a new collection. | |
add ( Puli\Repository\Api\Resource\PuliResource $resource ) | Not supported. | |
clear ( ) | Not supported. | |
count ( ) | ||
get ( $key ) | ||
getIterator ( $mode = ResourceCollectionIterator::KEY_AS_CURSOR ) | ||
getNames ( ) | ||
getPaths ( ) | ||
has ( $key ) | ||
isEmpty ( ) | ||
keys ( ) | ||
merge ( Puli\Repository\Api\Resource\PuliResource[] | Traversabl\Traversable $resources ) | Not supported. | |
offsetExists ( $key ) | ||
offsetGet ( $key ) | ||
offsetSet ( string $key, Puli\Repository\Api\Resource\PuliResource $resource ) | Not supported. | |
offsetUnset ( string $key ) | Not supported. | |
remove ( string $key ) | Not supported. | |
replace ( Puli\Repository\Api\Resource\PuliResource[] | Traversabl\Traversable $resources ) | Not supported. | |
set ( integer $key, Puli\Repository\Api\Resource\PuliResource $resource ) | Not supported. | |
toArray ( ) |
Méthode | Description | |
---|---|---|
load ( ) | Loads the complete collection. |
public __construct ( Puli\Repository\Api\ResourceRepository $repo, array $paths ) | ||
$repo | Puli\Repository\Api\ResourceRepository | The repository that will be used to load the resources. |
$paths | array | The paths of the resources which will be loaded into the collection. |
public add ( Puli\Repository\Api\Resource\PuliResource $resource ) | ||
$resource | Puli\Repository\Api\Resource\PuliResource | The resource to add. |
public getIterator ( $mode = ResourceCollectionIterator::KEY_AS_CURSOR ) |
public merge ( Puli\Repository\Api\Resource\PuliResource[] | Traversabl\Traversable $resources ) | ||
$resources | Puli\Repository\Api\Resource\PuliResource[] | Traversabl\Traversable | The resources to merge into the collection. |
public offsetUnset ( string $key ) | ||
$key | string | The collection key to remove. |
public replace ( Puli\Repository\Api\Resource\PuliResource[] | Traversabl\Traversable $resources ) | ||
$resources | Puli\Repository\Api\Resource\PuliResource[] | Traversabl\Traversable | The resources to replace the collection contents with. |