PHP Класс Bolt\Asset\Snippet\Queue

Автор: Gawain Lynch ([email protected])
Автор: Bob den Otter ([email protected])
Наследование: implements Bolt\Asset\QueueInterface
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$addJquery Whether to add jQuery to the HTML
$cache Doctrine\Common\Cache\CacheProvider
$config Bolt\Config
$injector Bolt\Asset\Injector
$queue Queue with snippets of HTML to insert.
$resources Bolt\Configuration\ResourceManager

Открытые методы

Метод Описание
__construct ( Bolt\Asset\Injector $injector, CacheProvider $cache, Config $config, ResourceManager $resources ) Constructor.
add ( Bolt\Asset\Snippet\SnippetAssetInterface $snippet ) Insert a snippet. And by 'insert' we actually mean 'add it to the queue, to be processed later'.
clear ( )
getQueue ( ) : Bolt\Asset\Snippet\Snippet[] Get the queued snippets.
process ( Request $request, Response $response )

Защищенные методы

Метод Описание
addJquery ( Request $request, Response $response ) Insert jQuery, if it's not inserted already.

Приватные методы

Метод Описание
pregCallback ( string $c ) : string Callback method to identify comments and store them in the matchedComments array.

Описание методов

__construct() публичный Метод

Constructor.
public __construct ( Bolt\Asset\Injector $injector, CacheProvider $cache, Config $config, ResourceManager $resources )
$injector Bolt\Asset\Injector
$cache Doctrine\Common\Cache\CacheProvider
$config Bolt\Config
$resources Bolt\Configuration\ResourceManager

add() публичный Метод

Insert a snippet. And by 'insert' we actually mean 'add it to the queue, to be processed later'.
public add ( Bolt\Asset\Snippet\SnippetAssetInterface $snippet )
$snippet Bolt\Asset\Snippet\SnippetAssetInterface

addJquery() защищенный Метод

Some of the patterns that 'match' are: - jquery.js - jquery.min.js - jquery-latest.js - jquery-latest.min.js - jquery-1.8.2.min.js - jquery-1.5.js
protected addJquery ( Request $request, Response $response )
$request Symfony\Component\HttpFoundation\Request
$response Symfony\Component\HttpFoundation\Response

clear() публичный Метод

public clear ( )

getQueue() публичный Метод

Get the queued snippets.
public getQueue ( ) : Bolt\Asset\Snippet\Snippet[]
Результат Bolt\Asset\Snippet\Snippet[]

process() публичный Метод

public process ( Request $request, Response $response )
$request Symfony\Component\HttpFoundation\Request
$response Symfony\Component\HttpFoundation\Response

Описание свойств

$addJquery защищенное свойство

Whether to add jQuery to the HTML
protected $addJquery

$cache защищенное свойство

protected CacheProvider,Doctrine\Common\Cache $cache
Результат Doctrine\Common\Cache\CacheProvider

$config защищенное свойство

protected Config,Bolt $config
Результат Bolt\Config

$injector защищенное свойство

protected Injector,Bolt\Asset $injector
Результат Bolt\Asset\Injector

$queue защищенное свойство

Queue with snippets of HTML to insert.
protected $queue

$resources защищенное свойство

protected ResourceManager,Bolt\Configuration $resources
Результат Bolt\Configuration\ResourceManager