ILIAS  release_5-2 Revision v5.2.25-18-g3f80b82851
Assetic\Asset\AssetCollectionInterface Interface Reference

An asset collection. More...

+ Inheritance diagram for Assetic\Asset\AssetCollectionInterface:
+ Collaboration diagram for Assetic\Asset\AssetCollectionInterface:

Public Member Functions

 all ()
 Returns all child assets. More...
 
 add (AssetInterface $asset)
 Adds an asset to the current collection. More...
 
 removeLeaf (AssetInterface $leaf, $graceful=false)
 Removes a leaf. More...
 
 replaceLeaf (AssetInterface $needle, AssetInterface $replacement, $graceful=false)
 Replaces an existing leaf with a new one. More...
 
- Public Member Functions inherited from Assetic\Asset\AssetInterface
 ensureFilter (FilterInterface $filter)
 Ensures the current asset includes the supplied filter. More...
 
 getFilters ()
 Returns an array of filters currently applied. More...
 
 clearFilters ()
 Clears all filters from the current asset. More...
 
 load (FilterInterface $additionalFilter=null)
 Loads the asset into memory and applies load filters. More...
 
 dump (FilterInterface $additionalFilter=null)
 Applies dump filters and returns the asset as a string. More...
 
 getContent ()
 Returns the loaded content of the current asset. More...
 
 setContent ($content)
 Sets the content of the current asset. More...
 
 getSourceRoot ()
 Returns an absolute path or URL to the source asset's root directory. More...
 
 getSourcePath ()
 Returns the relative path for the source asset. More...
 
 getSourceDirectory ()
 Returns the asset's source directory. More...
 
 getTargetPath ()
 Returns the URL for the current asset. More...
 
 setTargetPath ($targetPath)
 Sets the URL for the current asset. More...
 
 getLastModified ()
 Returns the time the current asset was last modified. More...
 
 getVars ()
 Returns an array of variable names for this asset. More...
 
 setValues (array $values)
 Sets the values for the asset's variables. More...
 
 getValues ()
 Returns the current values for this asset. More...
 

Detailed Description

An asset collection.

Author
Kris Wallsmith kris..nosp@m.wall.nosp@m.smith.nosp@m.@gma.nosp@m.il.co.nosp@m.m

Definition at line 19 of file AssetCollectionInterface.php.

Member Function Documentation

◆ add()

Assetic\Asset\AssetCollectionInterface::add ( AssetInterface  $asset)

Adds an asset to the current collection.

Parameters
AssetInterface$assetAn asset

Implemented in Assetic\Asset\AssetCollection.

◆ all()

Assetic\Asset\AssetCollectionInterface::all ( )

Returns all child assets.

Returns
array An array of AssetInterface objects

Implemented in Assetic\Asset\AssetCollection, and Assetic\Asset\GlobAsset.

Referenced by Assetic\Asset\Iterator\AssetCollectionIterator\__construct().

+ Here is the caller graph for this function:

◆ removeLeaf()

Assetic\Asset\AssetCollectionInterface::removeLeaf ( AssetInterface  $leaf,
  $graceful = false 
)

Removes a leaf.

Parameters
AssetInterface$leafThe leaf to remove
Boolean$gracefulWhether the failure should return false or throw an exception
Returns
Boolean Whether the asset has been found
Exceptions

Implemented in Assetic\Asset\AssetCollection.

Referenced by Assetic\Asset\AssetCollection\removeLeaf().

+ Here is the caller graph for this function:

◆ replaceLeaf()

Assetic\Asset\AssetCollectionInterface::replaceLeaf ( AssetInterface  $needle,
AssetInterface  $replacement,
  $graceful = false 
)

Replaces an existing leaf with a new one.

Parameters
AssetInterface$needleThe current asset to replace
AssetInterface$replacementThe new asset
Boolean$gracefulWhether the failure should return false or throw an exception
Returns
Boolean Whether the asset has been found
Exceptions

Implemented in Assetic\Asset\AssetCollection.

Referenced by Assetic\Factory\AssetFactory\applyWorkers(), and Assetic\Asset\AssetCollection\replaceLeaf().

+ Here is the caller graph for this function:

The documentation for this interface was generated from the following file: