PHP Class JacobBennett\Http2ServerPush\Middleware\AddHttp2ServerPush

Afficher le fichier Open project: jacobbennett/laravel-http2serverpush

Protected Properties

Свойство Type Description
$crawler Symfony\Component\DomCrawler\Crawler The DomCrawler instance.

Méthodes publiques

Méthode Description
handle ( Illuminate\Http\Request $request, Closure $next ) : mixed Handle an incoming request.

Méthodes protégées

Méthode Description
fetchLinkableNodes ( Illuminate\Http\Response $response ) : Collection Get all nodes we are interested in pushing.
generateAndAttachLinkHeaders ( Illuminate\Http\Response $response )
getCrawler ( Illuminate\Http\Response $response ) : Crawler Get the DomCrawler instance.

Private Methods

Méthode Description
addLinkHeader ( Illuminate\Http\Response $response, $link ) Add Link Header
buildLinkHeaderString ( string $url ) : string Build out header string based on asset extension.

Method Details

fetchLinkableNodes() protected méthode

Get all nodes we are interested in pushing.
protected fetchLinkableNodes ( Illuminate\Http\Response $response ) : Collection
$response Illuminate\Http\Response
Résultat Illuminate\Support\Collection

generateAndAttachLinkHeaders() protected méthode

protected generateAndAttachLinkHeaders ( Illuminate\Http\Response $response )
$response Illuminate\Http\Response

getCrawler() protected méthode

Get the DomCrawler instance.
protected getCrawler ( Illuminate\Http\Response $response ) : Crawler
$response Illuminate\Http\Response
Résultat Symfony\Component\DomCrawler\Crawler

handle() public méthode

Handle an incoming request.
public handle ( Illuminate\Http\Request $request, Closure $next ) : mixed
$request Illuminate\Http\Request
$next Closure
Résultat mixed

Property Details

$crawler protected_oe property

The DomCrawler instance.
protected Crawler,Symfony\Component\DomCrawler $crawler
Résultat Symfony\Component\DomCrawler\Crawler