Property | Type | Description | |
---|---|---|---|
$registered | array[SearchableInterface] | These are all the registered search providers that we will use in our universal search |
Method | Description | |
---|---|---|
__construct ( |
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 |
Method | Description | |
---|---|---|
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 |
public __construct ( |
||
$Pagination |
protected searchRegistered ( text $for, integer $limit ) : Collection | ||
$for | text | |
$limit | integer | |
return | Collection |