PHP 클래스 ScoutEngines\Elasticsearch\ElasticsearchEngine

상속: extends Laravel\Scout\Engines\Engine
파일 보기 프로젝트 열기: ericktamayo/laravel-scout-elastic 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$index string Index where the models will be saved.

공개 메소드들

메소드 설명
__construct ( Elasticsearch\Client $elastic, $index ) : void Create a new engine instance.
delete ( Illuminate\Database\Eloquent\Collection $models ) : void Remove the given model from the index.
getTotalCount ( mixed $results ) : integer Get the total count from a raw result returned by the engine.
map ( mixed $results, Model $model ) : Illuminate\Database\Eloquent\Collection Map the given results to instances of the given model.
paginate ( Laravel\Scout\Builder $builder, integer $perPage, integer $page ) : mixed Perform the given search on the engine.
search ( Laravel\Scout\Builder $builder ) : mixed Perform the given search on the engine.
update ( Illuminate\Database\Eloquent\Collection $models ) : void Update the given model in the index.

보호된 메소드들

메소드 설명
filters ( Laravel\Scout\Builder $builder ) : array Get the filter array for the query.
performSearch ( Laravel\Scout\Builder $builder, array $options = [] ) : mixed Perform the given search on the engine.

메소드 상세

__construct() 공개 메소드

Create a new engine instance.
public __construct ( Elasticsearch\Client $elastic, $index ) : void
$elastic Elasticsearch\Client
리턴 void

delete() 공개 메소드

Remove the given model from the index.
public delete ( Illuminate\Database\Eloquent\Collection $models ) : void
$models Illuminate\Database\Eloquent\Collection
리턴 void

filters() 보호된 메소드

Get the filter array for the query.
protected filters ( Laravel\Scout\Builder $builder ) : array
$builder Laravel\Scout\Builder
리턴 array

getTotalCount() 공개 메소드

Get the total count from a raw result returned by the engine.
public getTotalCount ( mixed $results ) : integer
$results mixed
리턴 integer

map() 공개 메소드

Map the given results to instances of the given model.
public map ( mixed $results, Model $model ) : Illuminate\Database\Eloquent\Collection
$results mixed
$model Illuminate\Database\Eloquent\Model
리턴 Illuminate\Database\Eloquent\Collection

paginate() 공개 메소드

Perform the given search on the engine.
public paginate ( Laravel\Scout\Builder $builder, integer $perPage, integer $page ) : mixed
$builder Laravel\Scout\Builder
$perPage integer
$page integer
리턴 mixed

performSearch() 보호된 메소드

Perform the given search on the engine.
protected performSearch ( Laravel\Scout\Builder $builder, array $options = [] ) : mixed
$builder Laravel\Scout\Builder
$options array
리턴 mixed

update() 공개 메소드

Update the given model in the index.
public update ( Illuminate\Database\Eloquent\Collection $models ) : void
$models Illuminate\Database\Eloquent\Collection
리턴 void

프로퍼티 상세

$index 보호되어 있는 프로퍼티

Index where the models will be saved.
protected string $index
리턴 string