@API(value=MAINTAINED) public class OneOfThem extends Object
Constructor and Description |
---|
OneOfThem(String fieldName) |
OneOfThem(String fieldName,
Field.OneOfThemEmptyMode emptyMode) |
Modifier and Type | Method and Description |
---|---|
QueryComponent |
equalsValue(Object comparand)
Checks if one of the values in this repeated field is equal to the given comparand.
|
QueryComponent |
greaterThan(Object comparand)
Checks if one of the values in this repeated field is greater than the given comparand.
|
QueryComponent |
greaterThanOrEquals(Object comparand)
Checks if one of the values in this repeated field is greater than or equal to the given comparand.
|
QueryComponent |
in(List<?> comparand)
Checks if one of the values in this repeated field is in the given list.
|
QueryComponent |
in(String param)
Checks if one of the values in this repeated field is in the list that is bound to the given param.
|
QueryComponent |
lessThan(Object comparand)
Checks if one of the values in this repeated field is less than the given comparand.
|
QueryComponent |
lessThanOrEquals(Object comparand)
Checks if one of the values in this repeated field is less than or equal to the given comparand.
|
QueryComponent |
matches(QueryComponent child)
If the associated field is a submessage, this allows you to match against the fields within that submessage.
|
QueryComponent |
notEquals(Object comparand)
Checks if one of the values in this repeated field is not equal to the given comparand.
|
QueryComponent |
startsWith(String comparand)
Checks if one of the values in this repeated field starts with the given string.
|
Text |
text()
Checks if one of the values in this repeated field matches some property when performing a full-text
search.
|
Text |
text(String tokenizerName)
Checks if one of the values in this repeated field matches some property when performing a full-text
search.
|
Text |
text(String tokenizerName,
String defaultTokenizerName)
Checks if one of the values in this repeated field matches some property when performing a full-text
search.
|
public OneOfThem(@Nonnull String fieldName, Field.OneOfThemEmptyMode emptyMode)
@Nonnull public QueryComponent matches(@Nonnull QueryComponent child)
child
- a component asserting about the content of the submessage in this field@Nonnull public QueryComponent equalsValue(@Nonnull Object comparand)
comparand
- the object to compare with the value in the field@Nonnull public QueryComponent notEquals(@Nonnull Object comparand)
comparand
- the object to compare with the value in the field@Nonnull public QueryComponent greaterThan(@Nonnull Object comparand)
comparand
- the object to compare with the value in the field@Nonnull public QueryComponent greaterThanOrEquals(@Nonnull Object comparand)
comparand
- the object to compare with the value in the field@Nonnull public QueryComponent lessThan(@Nonnull Object comparand)
comparand
- the object to compare with the value in the field@Nonnull public QueryComponent lessThanOrEquals(@Nonnull Object comparand)
comparand
- the object to compare with the value in the field@Nonnull public QueryComponent startsWith(@Nonnull String comparand)
comparand
- the object to compare with the value in the field@Nonnull public QueryComponent in(@Nonnull List<?> comparand)
comparand
- a list of elements@Nonnull public QueryComponent in(@Nonnull String param)
param
- a param that will be bound to a list in the execution context@Nonnull public Text text()
@Nonnull public Text text(@Nullable String tokenizerName)
tokenizerName
is not null
, then this will use that tokenizer
to tokenize the query string (if not already tokenized) and to parse the record's text. If
an index is used, then it is guaranteed that the index uses this same tokenizer. If
tokenizerName
is null
, then this behaves the same as text()
.tokenizerName
- the name of the tokenizer to use to tokenize the record and (if necessary) the query string@Nonnull public Text text(@Nullable String tokenizerName, @Nullable String defaultTokenizerName)
tokenizerName
is not null
, then this will use that tokenizer
to tokenize the query string (if not already tokenized) and to parse the record's text. If
an index is used, then it is guaranteed that the index uses this same tokenizer. If
tokenizerName
is null
, then this behaves the same as text()
except that if defaultTokenizerName
is not null
, then it will use
that tokenizer to tokenize the document and query string (if no index is available) instead
of the normal default tokenizer, DefaultTextTokenizer
.tokenizerName
- the name of the tokenizer to use to tokenize the record and (if necessary) the query stringdefaultTokenizerName
- the name of the tokenizer to use if tokenizerName
is null
and no index can be found to satisfy the query