CWP\Search\CwpSearchResult
Container for a set of search results
Synopsis
class CwpSearchResult
extends ViewableData
{
- // members
- private static array $casting = ;
- protected PaginatedList $matches;
- protected $query;
- protected $suggestion;
- protected PaginatedList $original;
- // methods
- public void __construct()
- public PaginatedList getResults()
- public bool hasResults()
- public string getQuery()
- public string getSuggestion()
- public string getOriginal()
- public void setOriginal()
- public string getSuggestionLink()
- public string getSearchLink()
- public string getOriginalLink()
- public string getRSSLink()
- public string getAtomLink()
- protected string|null getLink()
- public void hasField()
Hierarchy
Extends
- SilverStripe\View\ViewableData
Members
private
- $casting
protected
- $matches
—
SilverStripe\ORM\PaginatedList
List of results - $original
—
SilverStripe\ORM\PaginatedList
Original terms superceded by these result. - $query
—
string
Search terms for these results - $suggestion
—
string
Suggested search keywords Used when this search has suggested terms, but following suggestions isn't enabled
Methods
protected
- getLink() — Get a search link for given terms
public
- __construct() — Create a new CwpSearchResult
- getAtomLink() — Get link to these results in atom format
- getOriginal() — Get original search keywords superceded by these results
- getOriginalLink() — Gets the link to the original search, with suggestions disabled
- getQuery() — Get search keywords matching these results
- getRSSLink() — Get link to these results in RSS format
- getResults() — Get search results
- getSearchLink() — Gets the link to the given search
- getSuggestion() — Get suggested search keywords
- getSuggestionLink() — Get the link to the suggested search
- hasField()
- hasResults() — Check if there are found results
- setOriginal() — Set original keywords