PHP Трейт Sleimanx2\Plastic\Searchable

Показать файл Открыть проект

Открытые свойства

Свойство Тип Описание
$documentScore null | integer Hit score after querying Elasticsearch.
$documentVersion null | integer Elasticsearch document version.
$isDocument boolean Is indexed in elastic search.

Открытые методы

Метод Описание
__call ( string $method, array $parameters ) : mixed Handle dynamic method calls into the model.
bootSearchable ( ) Searchable boot model.
document ( ) : EloquentPersistence Start an elastic persistence query builder.
getDocumentData ( ) : array Build the document data with the appropriate method.
getDocumentIndex ( ) : mixed Get the model elastic index if available.
getDocumentType ( ) : string Get the model elastic type.
shouldSyncDocument ( ) : boolean; Checks if the model content should be auto synced with elastic.

Защищенные методы

Метод Описание
buildDocumentFromArray ( array $searchable ) : array Build the document from a searchable array.

Описание методов

__call() публичный Метод

Handle dynamic method calls into the model.
public __call ( string $method, array $parameters ) : mixed
$method string
$parameters array
Результат mixed

bootSearchable() публичный статический Метод

Searchable boot model.
public static bootSearchable ( )

buildDocumentFromArray() защищенный Метод

Build the document from a searchable array.
protected buildDocumentFromArray ( array $searchable ) : array
$searchable array
Результат array

document() публичный Метод

Start an elastic persistence query builder.
public document ( ) : EloquentPersistence
Результат Sleimanx2\Plastic\Persistence\EloquentPersistence

getDocumentData() публичный Метод

Build the document data with the appropriate method.
public getDocumentData ( ) : array
Результат array

getDocumentIndex() публичный Метод

Get the model elastic index if available.
public getDocumentIndex ( ) : mixed
Результат mixed

getDocumentType() публичный Метод

Get the model elastic type.
public getDocumentType ( ) : string
Результат string

shouldSyncDocument() публичный Метод

Checks if the model content should be auto synced with elastic.
public shouldSyncDocument ( ) : boolean;
Результат boolean;

Описание свойств

$documentScore публичное свойство

Hit score after querying Elasticsearch.
public null|int $documentScore
Результат null | integer

$documentVersion публичное свойство

Elasticsearch document version.
public null|int $documentVersion
Результат null | integer

$isDocument публичное свойство

Is indexed in elastic search.
public bool $isDocument
Результат boolean