PHP Class AssetManager\Controller\ConsoleController

Inheritance: extends Zend\Mvc\Controller\AbstractActionController
Datei anzeigen Open project: rwoverdijk/assetmanager Class Usage Examples

Protected Properties

Property Type Description
$appConfig associative array represents app config
$assetManager asset manager object
$console console object

Public Methods

Method Description
__construct ( Zend\Console\Adapter\AdapterInterface $console, AssetManager $assetManager, array $appConfig )
dispatch ( Zend\Stdlib\RequestInterface $request, Zend\Stdlib\ResponseInterface $response = null ) : mixed | Zend\Stdlib\ResponseInterface
warmupAction ( ) Dumps all assets to cache directories.

Protected Methods

Method Description
output ( $line, boolean $verbose = true ) Outputs given $line if $verbose i truthy value.
purgeCache ( boolean $verbose = false ) : boolean Purges all directories defined as AssetManager cache dir.
recursiveRemove ( string $node, boolean $verbose = false ) Removes given node from filesystem (recursively).

Method Details

__construct() public method

public __construct ( Zend\Console\Adapter\AdapterInterface $console, AssetManager $assetManager, array $appConfig )
$console Zend\Console\Adapter\AdapterInterface
$assetManager AssetManager\Service\AssetManager
$appConfig array

dispatch() public method

public dispatch ( Zend\Stdlib\RequestInterface $request, Zend\Stdlib\ResponseInterface $response = null ) : mixed | Zend\Stdlib\ResponseInterface
$request Zend\Stdlib\RequestInterface
$response Zend\Stdlib\ResponseInterface
return mixed | Zend\Stdlib\ResponseInterface

output() protected method

Outputs given $line if $verbose i truthy value.
protected output ( $line, boolean $verbose = true )
$line
$verbose boolean verbose flag, default true

purgeCache() protected method

Purges all directories defined as AssetManager cache dir.
protected purgeCache ( boolean $verbose = false ) : boolean
$verbose boolean verbose flag, default false
return boolean false if caching is not set, otherwise true

recursiveRemove() protected method

Removes given node from filesystem (recursively).
protected recursiveRemove ( string $node, boolean $verbose = false )
$node string - uri of node that should be removed from filesystem
$verbose boolean verbose flag, default false

warmupAction() public method

Dumps all assets to cache directories.
public warmupAction ( )

Property Details

$appConfig protected_oe property

associative array represents app config
protected $appConfig

$assetManager protected_oe property

asset manager object
protected $assetManager

$console protected_oe property

console object
protected $console