Class PredicateSuggestion
- java.lang.Object
-
- com.adobe.granite.omnisearch.api.suggestion.PredicateSuggestion
-
@ProviderType public final class PredicateSuggestion extends java.lang.ObjectTODO Need to confirm from UI what else information they require to show a predicate as SuggestionPredicateSuggestionclass have all the properties of a predicate that is require to show predicate as a suggestion on UI.
-
-
Constructor Summary
Constructors Constructor Description PredicateSuggestion(java.lang.String type, java.lang.String optionTitle)Creates a new instance ofPredicateSuggestioni.e.PredicateSuggestion(java.lang.String type, java.lang.String optionTitle, java.lang.String typePath, java.lang.String optionPath)Creates a new instance ofPredicateSuggestioni.e.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetOptionPath()java.lang.StringgetOptionTitle()java.util.Map<java.lang.String,java.lang.String>getQueryParameters()java.lang.StringgetType()java.lang.StringgetTypePath()voidsetQueryParameters(java.util.Map<java.lang.String,java.lang.String> queryParameters)
-
-
-
Constructor Detail
-
PredicateSuggestion
public PredicateSuggestion(java.lang.String type, java.lang.String optionTitle)Creates a new instance ofPredicateSuggestioni.e. File Type: Image- Parameters:
type- Type of predicate i.e. "File Type"optionTitle- Title of predicate option i.e. "Image"
-
PredicateSuggestion
public PredicateSuggestion(java.lang.String type, java.lang.String optionTitle, java.lang.String typePath, java.lang.String optionPath)Creates a new instance ofPredicateSuggestioni.e. File Type: Image- Parameters:
type- Type of predicate i.e. "File Type"optionTitle- Title of predicate option i.e. "Image"typePath- Path of the type node in the JCRoptionPath- Ppath of the node from where option is read in jcr.
-
-
Method Detail
-
getType
public java.lang.String getType()
- Returns:
- This is type of predicate. This is usually read from "text" property of predicate. Please note that title is returned in default lang i.e. en. Should be converted using i18n before rendering
-
getTypePath
public java.lang.String getTypePath()
- Returns:
- Path of the node from where type property has been read i.e. path of the predicate node
-
getOptionTitle
public java.lang.String getOptionTitle()
- Returns:
- title of predicate value/option. This is usually read from "jcr:title" property of option of predicate. Please note that title is returned in default lang i.e. en. Should be converted using i18n before rendering
-
getOptionPath
public java.lang.String getOptionPath()
- Returns:
- Path of the node from where option is read in jcr.
-
getQueryParameters
public java.util.Map<java.lang.String,java.lang.String> getQueryParameters()
- Returns:
- Map of all the queryParameters that are associated with PredicateSuggestions
-
setQueryParameters
public void setQueryParameters(java.util.Map<java.lang.String,java.lang.String> queryParameters)
- Parameters:
queryParameters-Mapof Parameters that needed to be included inPredicateSuggestion
-
-