23 private $assets = array();
34 public function get($name)
36 if (!isset($this->assets[$name])) {
37 throw new \InvalidArgumentException(
sprintf(
'There is no "%s" asset.', $name));
40 return $this->assets[$name];
50 public function has($name)
52 return isset($this->assets[$name]);
65 if (!ctype_alnum(str_replace(
'_',
'', $name))) {
66 throw new \InvalidArgumentException(
sprintf(
'The name "%s" is invalid.', $name));
69 $this->assets[$name] = $asset;
79 return array_keys($this->assets);
87 $this->assets = array();
sprintf('%.4f', $callTime)
clear()
Clears all assets.
getNames()
Returns an array of asset names.
has($name)
Checks if the current asset manager has a certain asset.
An exception for terminatinating execution or to throw for unit testing.
An asset has a mutable URL and content and can be loaded and dumped.
Class CssCacheBustingFilter.