PreloadManager
Manager for HTTP/2 asset preloading
since |
2.0.0 |
---|---|
package |
Joomla Framework |
Methods
__construct
PreloadManager constructor
__construct(\Psr\Link\EvolvableLinkProviderInterface linkProvider = null) : mixed
since |
2.0.0 |
---|
Arguments
- linkProvider
\Psr\Link\EvolvableLinkProviderInterface
The link provider
Response
mixed
dnsPrefetch
Resolves a resource origin as early as possible.
dnsPrefetch(string uri, array attributes = []) : void
since |
2.0.0 |
---|
Arguments
- uri
string
The relation URI- attributes
array
The attributes of this link (e.g. "array('as' => true)", "array('pr' => 0.5)")
getLinkProvider
Get the link provider
getLinkProvider() : \Psr\Link\EvolvableLinkProviderInterface
since |
2.0.0 |
---|
Response
\Psr\Link\EvolvableLinkProviderInterface
link
Adds a "Link" HTTP header.
link(string uri, string rel, array attributes = []) : void
since |
2.0.0 |
---|
Arguments
- uri
string
The relation URI- rel
string
The relation type (e.g. "preload", "prefetch", "prerender" or "dns-prefetch")- attributes
array
The attributes of this link (e.g. "array('as' => true)", "array('pr' => 0.5)")
preconnect
Initiates a early connection to a resource (DNS resolution, TCP handshake, TLS negotiation).
preconnect(string uri, array attributes = []) : void
since |
2.0.0 |
---|
Arguments
- uri
string
The relation URI- attributes
array
The attributes of this link (e.g. "array('as' => true)", "array('pr' => 0.5)")
prefetch
Indicates to the client that it should prefetch this resource.
prefetch(string uri, array attributes = []) : void
since |
2.0.0 |
---|
Arguments
- uri
string
The relation URI- attributes
array
The attributes of this link (e.g. "array('as' => true)", "array('pr' => 0.5)")
preload
Preloads a resource.
preload(string uri, array attributes = []) : void
since |
2.0.0 |
---|
Arguments
- uri
string
The relation URI- attributes
array
The attributes of this link (e.g. "array('as' => true)", "array('crossorigin' => 'use-credentials')")
prerender
Indicates to the client that it should prerender this resource.
prerender(string uri, array attributes = []) : void
since |
2.0.0 |
---|
Arguments
- uri
string
The relation URI- attributes
array
The attributes of this link (e.g. "array('as' => true)", "array('pr' => 0.5)")
setLinkProvider
Set the link provider
setLinkProvider(\Psr\Link\EvolvableLinkProviderInterface linkProvider) : void
since |
2.0.0 |
---|
Arguments
- linkProvider
\Psr\Link\EvolvableLinkProviderInterface
The link provider
Properties
linkProvider
The link provider
since |
2.0.0 |
---|
Type(s)
\Psr\Link\EvolvableLinkProviderInterface