abstract class Data implements Stringable (View source)

Traits

Methods

array
tokens()

Get the tokens.

Token|Data|null
tokenAt(int $index)

Get the response token at the given index.

array
tokensAfter(int $index)

Get the response tokens after the given index.

__construct(array $tokens)

Constructor.

Token|Data|null
first()

Get the first token.

Token|Data|null
last()

Get the last token.

bool
contains(array|string $needles)

Determine if the data contains a specific value.

array
values()

Get all the token's values.

Details

array tokens()

Get the tokens.

Return Value

array

Token|Data|null tokenAt(int $index)

Get the response token at the given index.

Parameters

int $index

Return Value

Token|Data|null

array tokensAfter(int $index)

Get the response tokens after the given index.

Parameters

int $index

Return Value

array

__construct(array $tokens)

Constructor.

Parameters

array $tokens

Token|Data|null first()

Get the first token.

Return Value

Token|Data|null

Token|Data|null last()

Get the last token.

Return Value

Token|Data|null

bool contains(array|string $needles)

Determine if the data contains a specific value.

Parameters

array|string $needles

Return Value

bool

array values()

Get all the token's values.

Return Value

array