Class SearchKeywordBuilder
java.lang.Object
com.commercetools.api.models.product.SearchKeywordBuilder
- All Implemented Interfaces:
io.vrap.rmf.base.client.Builder<SearchKeyword>
public class SearchKeywordBuilder
extends Object
implements io.vrap.rmf.base.client.Builder<SearchKeyword>
SearchKeywordBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
SearchKeyword searchKeyword = SearchKeyword.builder()
.text("{text}")
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds SearchKeyword with checking for non-null required valuesbuilds SearchKeyword without checking for non-null required valuesIf no tokenizer is defined, thetext
is used as a single token.getText()
Text to return in the result of a suggest query.static SearchKeywordBuilder
of()
factory method for an instance of SearchKeywordBuilderstatic SearchKeywordBuilder
of
(SearchKeyword template) create builder for SearchKeyword instancesuggestTokenizer
(SuggestTokenizer suggestTokenizer) If no tokenizer is defined, thetext
is used as a single token.suggestTokenizer
(Function<SuggestTokenizerBuilder, io.vrap.rmf.base.client.Builder<? extends SuggestTokenizer>> builder) If no tokenizer is defined, thetext
is used as a single token.Text to return in the result of a suggest query.
-
Constructor Details
-
SearchKeywordBuilder
public SearchKeywordBuilder()
-
-
Method Details
-
text
Text to return in the result of a suggest query.
- Parameters:
text
- value to be set- Returns:
- Builder
-
suggestTokenizer
If no tokenizer is defined, the
text
is used as a single token.- Parameters:
suggestTokenizer
- value to be set- Returns:
- Builder
-
suggestTokenizer
public SearchKeywordBuilder suggestTokenizer(Function<SuggestTokenizerBuilder, io.vrap.rmf.base.client.Builder<? extends SuggestTokenizer>> builder) If no tokenizer is defined, the
text
is used as a single token.- Parameters:
builder
- function to build the suggestTokenizer value- Returns:
- Builder
-
getText
Text to return in the result of a suggest query.
- Returns:
- text
-
getSuggestTokenizer
If no tokenizer is defined, the
text
is used as a single token.- Returns:
- suggestTokenizer
-
build
builds SearchKeyword with checking for non-null required values- Specified by:
build
in interfaceio.vrap.rmf.base.client.Builder<SearchKeyword>
- Returns:
- SearchKeyword
-
buildUnchecked
builds SearchKeyword without checking for non-null required values- Returns:
- SearchKeyword
-
of
factory method for an instance of SearchKeywordBuilder- Returns:
- builder
-
of
create builder for SearchKeyword instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-