GenericLinkProvider
in package
implements
EvolvableLinkProviderInterface
Interfaces, Classes, Traits and Enums
- EvolvableLinkProviderInterface
- An evolvable link provider value object.
Table of Contents
- $links : array<string|int, LinkInterface>
- __construct() : mixed
- getLinks() : array<string|int, mixed>
- {@inheritdoc}
- getLinksByRel() : array<string|int, mixed>
- {@inheritdoc}
- withLink() : static
- Returns an instance with the specified link included.
- withoutLink() : static
- Returns an instance with the specifed link removed.
Properties
$links
private
array<string|int, LinkInterface>
$links
= []
Methods
__construct()
public
__construct([array<string|int, LinkInterface> $links = [] ]) : mixed
Parameters
- $links : array<string|int, LinkInterface> = []
Return values
mixed —getLinks()
{@inheritdoc}
public
getLinks() : array<string|int, mixed>
Return values
array<string|int, mixed> —getLinksByRel()
{@inheritdoc}
public
getLinksByRel(mixed $rel) : array<string|int, mixed>
Parameters
- $rel : mixed
Return values
array<string|int, mixed> —withLink()
Returns an instance with the specified link included.
public
withLink(LinkInterface $link) : static
Parameters
- $link : LinkInterface
-
A link object that should be included in this collection.
Return values
static —withoutLink()
Returns an instance with the specifed link removed.
public
withoutLink(LinkInterface $link) : static
Parameters
- $link : LinkInterface
-
The link to remove.