Phalcon assets   NOTE
 All classes are prefixed with Phalcon
   Assets\Asset  Source on GitHub 
   Namespace 
     Uses 
    Extends 
    Implements 
      Represents an asset
 $asset  =  new  \Phalcon\Assets\Asset ( "js" ,  "js/jquery.js" ); 
Properties  /** 
 * @var array | null 
 */ 
protected  $attributes ; 
/** 
 * @var bool 
 */ 
protected  $autoVersion  =  false ; 
/** 
 * @var bool 
 */ 
protected  $filter ; 
/** 
 * @var bool 
 */ 
protected  $local ; 
/** 
 * @var string 
 */ 
protected  $path ; 
/** 
 * @var string 
 */ 
protected  $sourcePath ; 
/** 
 * @var string 
 */ 
protected  $targetPath ; 
/** 
 * @var string 
 */ 
protected  $targetUri ; 
/** 
 * @var string 
 */ 
protected  $type ; 
/** 
 * Version of resource 
 * 
 * @var string 
 */ 
protected  $version ; 
Methods  
public  function  __construct (  string  $type ,  string  $path ,  bool  $local  =  bool ,  bool  $filter  =  bool ,  array  $attributes  =  [],  string  $version  =  null ,  bool  $autoVersion  =  bool  ); 
public  function  getAssetKey () :  string ; 
public  function  getAttributes () :  array  |  null 
public  function  getContent (  string  $basePath  =  null  ) :  string ; 
public  function  getFilter () :  bool ; 
public  function  getLocal () :  bool 
public  function  getPath () :  string ; 
public  function  getRealSourcePath (  string  $basePath  =  null  ) :  string ; 
public  function  getRealTargetPath (  string  $basePath  =  null  ) :  string ; 
public  function  getRealTargetUri () :  string ; 
public  function  getSourcePath () :  string ; 
public  function  getTargetPath () :  string ; 
public  function  getTargetUri () :  string ; 
public  function  getType () :  string ; 
public  function  getVersion () :  string ; 
public  function  isAutoVersion () :  bool ; 
public  function  setAttributes (  array  $attributes  ) :  AssetInterface ; 
public  function  setAutoVersion (  bool  $autoVersion  ) l 
public  function  setFilter (  bool  $filter  ) :  AssetInterface ; 
public  function  setLocal (  bool  $local  ) :  AssetInterface ; 
public  function  setPath (  string  $path  ) :  AssetInterface ; 
public  function  setSourcePath (  string  $sourcePath  ) :  AssetInterface ; 
public  function  setTargetPath (  string  $targetPath  ) :  AssetInterface ; 
public  function  setTargetUri (  string  $targetUri  ) :  AssetInterface ; 
public  function  setType (  string  $type  ) :  AssetInterface ; 
public  function  setVersion (  string  $version  ); 
Assets\Asset\Css  Source on GitHub 
   Namespace 
     Uses 
     Extends 
 AssetBase
    Implements 
     Represents CSS assets
 Methods  
public  function  __construct (  string  $path ,  bool  $local  =  bool ,  bool  $filter  =  bool ,  array  $attributes  =  [],  string  $version  =  null ,  bool  $autoVersion  =  bool  ); 
Assets\Asset\Js  Source on GitHub 
   Namespace 
     Uses 
     Extends 
 AssetBase
    Implements 
     Represents JavaScript assets
 Methods  
public  function  __construct (  string  $path ,  bool  $local  =  bool ,  bool  $filter  =  bool ,  array  $attributes  =  [],  string  $version  =  null ,  bool  $autoVersion  =  bool  ); 
Assets\AssetInterface   Source on GitHub 
   Namespace 
     Uses 
    Extends 
    Implements 
     Interface for custom Phalcon\Assets resources
 Methods  
public  function  getAssetKey () :  string ; 
public  function  getAttributes () :  array  |  null ; 
public  function  getFilter () :  bool ; 
public  function  getType () :  string ; 
public  function  setAttributes (  array  $attributes  ) :  AssetInterface ; 
public  function  setFilter (  bool  $filter  ) :  AssetInterface ; 
public  function  setType (  string  $type  ) :  AssetInterface ; 
Assets\Collection  Source on GitHub 
   Namespace 
     Uses 
  ArrayIteratorCountableIteratorAggregate     Extends 
    Implements 
  CountableIteratorAggregate      Collection of asset objects
 Properties  /** 
 * @var array 
 */ 
protected  $assets ; 
/** 
 * @var array 
 */ 
protected  $attributes ; 
/** 
 * Should version be determined from file modification time 
 * 
 * @var bool 
 */ 
protected  $autoVersion  =  false ; 
/** 
 * @var array 
 */ 
protected  $codes ; 
/** 
 * @var array 
 */ 
protected  $filters ; 
/** 
 * @var array 
 */ 
protected  $includedAssets ; 
/** 
 * @var bool 
 */ 
protected  $join  =  true ; 
/** 
 * @var bool 
 */ 
protected  $local  =  true ; 
/** 
 * @var string 
 */ 
protected  $prefix  =  '' ; 
/** 
 * @var int 
 */ 
protected  $position  =  0 ; 
/** 
 * @var string 
 */ 
protected  $sourcePath  =  '' ; 
/** 
 * @var bool 
 */ 
protected  $targetLocal  =  true ; 
/** 
 * @var string 
 */ 
protected  $targetPath  =  '' ; 
/** 
 * @var string 
 */ 
protected  $targetUri  =  '' ; 
/** 
 * @var string 
 */ 
protected  $version  =  '' ; 
Methods  
public  function  add (  AssetInterface  $asset  ) :  Collection ; 
public  function  addCss (  string  $path ,  mixed  $local  =  null ,  bool  $filter  =  bool ,  mixed  $attributes  =  null ,  string  $version  =  null ,  bool  $autoVersion  =  bool  ) :  Collection ; 
public  function  addFilter (  FilterInterface  $filter  ) :  Collection ; 
public  function  addInline (  Inline  $code  ) :  Collection ; 
public  function  addInlineCss (  string  $content ,  bool  $filter  =  bool ,  mixed  $attributes  =  null  ) :  Collection ; 
public  function  addInlineJs (  string  $content ,  bool  $filter  =  bool ,  mixed  $attributes  =  null  ) :  Collection ; 
public  function  addJs (  string  $path ,  mixed  $local  =  null ,  bool  $filter  =  bool ,  mixed  $attributes  =  null ,  string  $version  =  null ,  bool  $autoVersion  =  bool  ) :  Collection ; 
public  function  count () :  int ; 
public  function  current () :  Asset ; 
public  function  getAssets () :  array ; 
public  function  getAttributes () :  array ; 
public  function  getCodes () :  array ; 
public  function  getFilters () :  array ; 
public  function  getJoin () :  bool ; 
public  function  getLocal () :  bool ; 
public  function  getPosition () :  int ; 
public  function  getPrefix () :  string ; 
public  function  getRealTargetPath (  string  $basePath  ) :  string ; 
public  function  getSourcePath () :  string ; 
public  function  getTargetLocal () :  bool ; 
public  function  getTargetPath () :  string ; 
public  function  getTargetUri () :  string ; 
public  function  getVersion () :  string ; 
public  function  has (  AssetInterface  $asset  ) :  bool ; 
use  Phalcon\Assets\Asset ; 
use  Phalcon\Assets\Collection ; 
$collection  =  new  Collection (); 
$asset  =  new  Asset ( "js" ,  "js/jquery.js" ); 
$collection -> add ( $asset ); 
$collection -> has ( $asset );  // true 
public  function  isAutoVersion () :  bool ; 
public  function  join (  bool  $join  ) :  Collection ; 
public  function  key () :  int ; 
public  function  next () :  void ; 
public  function  rewind () :  void ; 
public  function  setAttributes (  array  $attributes  ) :  Collection ; 
public  function  setAutoVersion (  bool  $autoVersion  ) 
public  function  setFilters (  array  $filters  ) :  Collection ; 
public  function  setLocal (  bool  $local  ) :  Collection ; 
public  function  setPrefix (  string  $prefix  ) :  Collection ; 
public  function  setSourcePath (  string  $sourcePath  ) :  Collection ; 
public  function  setTargetLocal (  bool  $targetLocal  ) :  Collection ; 
public  function  setTargetPath (  string  $targetPath  ) :  Collection ; 
public  function  setTargetUri (  string  $targetUri  ) :  Collection ; 
public  function  setVersion (  string  $version  ) 
public  function  valid () :  bool ; 
final  protected  function  addAsset (  AssetInterface  $asset  ) :  bool ; 
Assets\Exception  Source on GitHub 
   Namespace 
     Uses 
    Extends 
 \Exception
    Implements 
     Exceptions thrown in Phalcon\Assets will use this class
 Assets\FilterInterface   Source on GitHub 
   Namespace 
     Uses 
    Extends 
    Implements 
     Interface for custom Phalcon\Assets filters
 Methods  
public  function  filter (  string  $content  ) :  string ; 
Assets\Filters\Cssmin  Source on GitHub 
   Namespace 
     Uses 
  Phalcon\Assets\FilterInterface     Extends 
    Implements 
      Minify the CSS - removes comments removes newlines and line feeds keeping removes last semicolon from last property
 Methods  
public  function  filter (  string  $content  ) :  string ; 
 NOTE
 This functionality is not currently available
   Assets\Filters\Jsmin  Source on GitHub 
   Namespace 
     Uses 
  Phalcon\Assets\FilterInterface     Extends 
    Implements 
      Deletes the characters which are insignificant to JavaScript. Comments will be removed. Tabs will be replaced with spaces. Carriage returns will be replaced with linefeeds. Most spaces and linefeeds will be removed.
 Methods  
public  function  filter (  string  $content  ) :  string ; 
 NOTE
 This functionality is not currently available
   NOTE: This functionality is not currently available
 Assets\Filters\None  Source on GitHub 
   Namespace 
     Uses 
  Phalcon\Assets\FilterInterface     Extends 
    Implements 
      Returns the content without make any modification to the original source
 Methods  
public  function  filter (  string  $content  ) :  string ; 
Assets\Inline  Source on GitHub 
   Namespace 
     Uses 
    Extends 
    Implements 
      Represents an inline asset
 $inline  =  new  \Phalcon\Assets\Inline ( "js" ,  "alert('hello world');" ); 
Properties  /** 
 * @var array | null 
 */ 
protected  $attributes ; 
/** 
 * @var string 
 */ 
protected  $content ; 
/** 
 * @var bool 
 */ 
protected  $filter ; 
/** 
 * @var string 
 */ 
protected  $type ; 
Methods  
public  function  __construct (  string  $type ,  string  $content ,  bool  $filter  =  bool ,  array  $attributes  =  []  ); 
public  function  getAssetKey () :  string ; 
public  function  getAttributes () :  array ; 
public  function  getContent () :  string ; 
public  function  getFilter () :  bool ; 
public  function  getType () :  string ; 
public  function  setAttributes (  array  $attributes  ) :  AssetInterface ; 
public  function  setFilter (  bool  $filter  ) :  AssetInterface ; 
public  function  setType (  string  $type  ) :  AssetInterface ; 
Assets\Inline\Css  Source on GitHub 
   Namespace 
     Uses 
     Extends 
 InlineBase
    Implements 
     Represents an inlined CSS
 Methods  
public  function  __construct (  string  $content ,  bool  $filter  =  bool ,  mixed  $attributes  =  null  ); 
Assets\Inline\Js  Source on GitHub 
   Namespace 
     Uses 
     Extends 
 InlineBase
    Implements 
     Represents an inline JavaScript
 Methods  
public  function  __construct (  string  $content ,  bool  $filter  =  bool ,  mixed  $attributes  =  null  ); 
Assets\Manager  Source on GitHub 
   Namespace 
     Uses 
  Phalcon\Assets\Asset\CssPhalcon\Assets\Asset\JsPhalcon\Assets\Inline\CssPhalcon\Assets\Inline\JsPhalcon\Di\AbstractInjectionAwarePhalcon\Html\Helper\ElementPhalcon\Html\Helper\LinkPhalcon\Html\Helper\ScriptPhalcon\Html\TagFactory     Extends 
 AbstractInjectionAware
    Implements 
     Manages collections of CSS/JavaScript assets
 Properties  /** 
 * @var array 
 */ 
protected  $collections ; 
/** 
 * @var bool 
 */ 
protected  $implicitOutput  =  true ; 
/** 
 * @var array 
 */ 
protected  $options ; 
Methods  
public  function  __construct (  array  $options  =  []  ); 
public  function  addAsset (  Asset  $asset  ) :  Manager ; 
$assets -> addAsset ( 
new  Phalcon\Assets\Asset ( "css" ,  "css/style.css" ) 
); 
public  function  addAssetByType (  string  $type ,  Asset  $asset  ) :  Manager ; 
$assets -> addAssetByType ( 
"css" , 
new  \Phalcon\Assets\Asset\Css ( "css/style.css" ) 
); 
public  function  addCss (  string  $path ,  mixed  $local  =  bool ,  bool  $filter  =  bool ,  mixed  $attributes  =  null ,  string  $version  =  null ,  bool  $autoVersion  =  bool  ) :  Manager ; 
$assets -> addCss ( "css/bootstrap.css" ); 
$assets -> addCss ( "http://bootstrap.my-cdn.com/style.css" ,  false ); 
public  function  addInlineCode (  Inline  $code  ) :  Manager ; 
public  function  addInlineCodeByType (  string  $type ,  Inline  $code  ) :  Manager ; 
public  function  addInlineCss (  string  $content ,  mixed  $filter  =  bool ,  mixed  $attributes  =  null  ) :  Manager ; 
public  function  addInlineJs (  string  $content ,  mixed  $filter  =  bool ,  mixed  $attributes  =  null  ) :  Manager ; 
public  function  addJs (  string  $path ,  mixed  $local  =  bool ,  bool  $filter  =  bool ,  mixed  $attributes  =  null ,  string  $version  =  null ,  bool  $autoVersion  =  bool  ) :  Manager ; 
$assets -> addJs ( "scripts/jquery.js" ); 
$assets -> addJs ( "http://jquery.my-cdn.com/jquery.js" ,  false ); 
public  function  collection (  string  $name  ) :  Collection ; 
public  function  collectionAssetsByType (  array  $assets ,  string  $type  ) :  array ; 
public  function  exists (  string  $id  ) :  bool ; 
if  ( $manager -> exists ( "jsHeader" ))  { 
// \Phalcon\Assets\Collection 
$collection  =  $manager -> get ( "jsHeader" ); 
} 
public  function  get (  string  $id  ) :  Collection ; 
$scripts  =  $assets -> get ( "js" ); 
public  function  getCollections () :  Collection []; 
public  function  getCss () :  Collection ; 
public  function  getJs () :  Collection ; 
public  function  getOptions () :  array ; 
public  function  output (  Collection  $collection ,  mixed  $callback ,  mixed  $type  ) :  string  |  null ; 
public  function  outputCss (  string  $collectionName  =  null  ) :  string ; 
public  function  outputInline (  Collection  $collection ,  mixed  $type  ) :  string ; 
public  function  outputInlineCss (  string  $collectionName  =  null  ) :  string ; 
public  function  outputInlineJs (  string  $collectionName  =  null  ) :  string ; 
public  function  outputJs (  string  $collectionName  =  null  ) :  string ; 
public  function  set (  string  $id ,  Collection  $collection  ) :  Manager ; 
$assets -> set ( "js" ,  $collection ); 
public  function  setOptions (  array  $options  ) :  Manager ; 
public  function  useImplicitOutput (  bool  $implicitOutput  ) :  Manager ;