class RankedDocument implements Arrayable, JsonSerializable, Stringable

Methods

__construct(int $index, string $document, float $score)

Create a new ranked document instance.

array
toArray()

Get the instance as an array.

array
jsonSerialize()

Get the JSON serializable representation of the instance.

string
__toString()

Get the document content.

Details

at line 16
__construct(int $index, string $document, float $score)

Create a new ranked document instance.

Parameters

int $index
string $document
float $score

at line 26
array toArray()

Get the instance as an array.

Return Value

array

at line 38
array jsonSerialize()

Get the JSON serializable representation of the instance.

Return Value

array

at line 46
string __toString()

Get the document content.

Return Value

string