PHP 클래스 Devise\Search\UniversalSearch

파일 보기 프로젝트 열기: devisephp/cms

보호된 프로퍼티들

프로퍼티 타입 설명
$registered array[SearchableInterface] These are all the registered search providers that we will use in our universal search

공개 메소드들

메소드 설명
__construct ( Pagination $Pagination ) Create a new universal search
register ( Searchable $item ) : void Provides a way to register new searchable items in our collection of Searchable items
search ( $for, integer $page = 1, integer $perPage = 10 ) : array Search through all registered searchers and put them together in results

보호된 메소드들

메소드 설명
searchRegistered ( text $for, integer $limit ) : Collection Search all the registered searchables
searchRegisteredSecondPass ( string $for, integer $limit, integer $leftover, Collection $collection ) : Collection On the second pass it's all about trying to take up as much of the leftovers as you want, like an all you can eat salad bar

메소드 상세

__construct() 공개 메소드

Create a new universal search
public __construct ( Pagination $Pagination )
$Pagination Pagination

register() 공개 메소드

Provides a way to register new searchable items in our collection of Searchable items
public register ( Searchable $item ) : void
$item Searchable
리턴 void

searchRegistered() 보호된 메소드

Search all the registered searchables
protected searchRegistered ( text $for, integer $limit ) : Collection
$for text
$limit integer
리턴 Collection

searchRegisteredSecondPass() 보호된 메소드

On the second pass it's all about trying to take up as much of the leftovers as you want, like an all you can eat salad bar
protected searchRegisteredSecondPass ( string $for, integer $limit, integer $leftover, Collection $collection ) : Collection
$for string
$limit integer
$leftover integer
$collection Collection
리턴 Collection

프로퍼티 상세

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

These are all the registered search providers that we will use in our universal search
protected array[SearchableInterface] $registered
리턴 array[SearchableInterface]