ISearchTemplate
Class ISearchTemplate
This is a data transfer object that should be created by Content Provider when the getSearchTemplate() method is called.
The object will contain templates to be displayed, and the list of the different options to be available to the user when he start a new search.
The display of the Options is generated by the FullTextSearch app and Options can be displayed in 2 places:
- the navigation page of the app that generate the indexed content. (files, bookmarks, deck, mails, ...)
 - the navigation page of the FullTextSearch app.
 
Both pages will have different Options, and only the first one can integrate a specific template.
Tags
Table of Contents
- addNavigationOption() : ISearchTemplate
 - Add an option in the left panel of the FullTextSearch navigation page.
 - addPanelOption() : ISearchTemplate
 - Add an option in the Panel that is displayed when the user start a search within the app that generate the content.
 - getCss() : string
 - Get the path of the CSS file.
 - getIcon() : string
 - Get the class of the icon.
 - getNavigationOptions() : array
 - Get all options to be displayed in the FullTextSearch navigation page.
 - getPanelOptions() : \OCP\FullTextSearch\Model\ISearchOption[]
 - Get all options to be displayed in the Panel.
 - getTemplate() : string
 - Get the path of the template file.
 - setCss() : ISearchTemplate
 - Set the path of a CSS file that will be loaded when needed.
 - setIcon() : ISearchTemplate
 - Set the class of the icon to be displayed in the left panel of the FullTextSearch navigation page, in front of the related Content Provider.
 - setTemplate() : ISearchTemplate
 - Set the path of the file of a template that the HTML will be displayed below the Options.
 
Methods
addNavigationOption()
Add an option in the left panel of the FullTextSearch navigation page.
    public
                addNavigationOption(ISearchOption $option) : ISearchTemplate
    
        Parameters
- $option : ISearchOption
 
Tags
Return values
ISearchTemplate —addPanelOption()
Add an option in the Panel that is displayed when the user start a search within the app that generate the content.
    public
                addPanelOption(ISearchOption $option) : ISearchTemplate
    
        Parameters
- $option : ISearchOption
 
Tags
Return values
ISearchTemplate —getCss()
Get the path of the CSS file.
    public
                getCss() : string
    
    
    
    Tags
Return values
string —getIcon()
Get the class of the icon.
    public
                getIcon() : string
    
    
    
    Tags
Return values
string —getNavigationOptions()
Get all options to be displayed in the FullTextSearch navigation page.
    public
                getNavigationOptions() : array
    
    
    
    Tags
Return values
array —getPanelOptions()
Get all options to be displayed in the Panel.
    public
                getPanelOptions() : \OCP\FullTextSearch\Model\ISearchOption[]
    
    
    
    Tags
Return values
\OCP\FullTextSearch\Model\ISearchOption[] —getTemplate()
Get the path of the template file.
    public
                getTemplate() : string
    
    
    
    Tags
Return values
string —setCss()
Set the path of a CSS file that will be loaded when needed.
    public
                setCss(string $css) : ISearchTemplate
    
        Parameters
- $css : string
 
Tags
Return values
ISearchTemplate —setIcon()
Set the class of the icon to be displayed in the left panel of the FullTextSearch navigation page, in front of the related Content Provider.
    public
                setIcon(string $class) : ISearchTemplate
    
        Parameters
- $class : string
 
Tags
Return values
ISearchTemplate —setTemplate()
Set the path of the file of a template that the HTML will be displayed below the Options.
    public
                setTemplate(string $template) : ISearchTemplate
        This should only be used if your Content Provider needs to set options in a way not generated by FullTextSearch
Parameters
- $template : string