Class PredicateSuggestion
java.lang.Object
com.adobe.granite.omnisearch.api.suggestion.PredicateSuggestion
TODO Need to confirm from UI what else information they require to show a predicate as Suggestion
PredicateSuggestion class have all the properties of
a predicate that is require to show predicate as a suggestion on UI.-
Constructor Summary
ConstructorsConstructorDescriptionPredicateSuggestion(String type, String optionTitle) Creates a new instance ofPredicateSuggestioni.e.PredicateSuggestion(String type, String optionTitle, String typePath, String optionPath) Creates a new instance ofPredicateSuggestioni.e. -
Method Summary
Modifier and TypeMethodDescriptiongetType()voidsetQueryParameters(Map<String, String> queryParameters)
-
Constructor Details
-
PredicateSuggestion
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
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 Details
-
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
- Returns:
- Path of the node from where type property has been read i.e. path of the predicate node
-
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
- Returns:
- Path of the node from where option is read in jcr.
-
getQueryParameters
- Returns:
- Map of all the queryParameters that are associated with PredicateSuggestions
-
setQueryParameters
- Parameters:
queryParameters-Mapof Parameters that needed to be included inPredicateSuggestion
-