Package org.ametys.cms.search.query
Class DateTimeQuery
java.lang.Object
org.ametys.cms.search.query.AbstractOperatorQuery<AdaptableDate>
org.ametys.cms.search.query.AbstractDateOperatorQuery
org.ametys.cms.search.query.DateTimeQuery
Represents a
Query
testing a datetime field.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.ametys.cms.search.query.Query
Query.LogicalOperator, Query.Operator
-
Field Summary
Fields inherited from class org.ametys.cms.search.query.AbstractDateOperatorQuery
DATE_FORMATTER
Fields inherited from interface org.ametys.cms.search.query.Query
BOOL_FILTER, BOOL_MUST, BOOL_MUST_NOT, BOOL_SHOULD
-
Constructor Summary
ConstructorDescriptionDateTimeQuery
(String fieldPath) Build a DateQuery testing the existence of the field.DateTimeQuery
(String fieldPath, ZonedDateTime value) Build a DateQuery.DateTimeQuery
(String fieldPath, Query.Operator op, ZonedDateTime value) Build a DateQuery.DateTimeQuery
(String fieldPath, Query.Operator op, AdaptableDate value) Build a DateQuery.DateTimeQuery
(String fieldPath, AdaptableDate value) Build a DateQuery. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
appendDateValue
(StringBuilder query, Query.Operator operator, AdaptableDate value) Format and append the given date to a StringBuilder.Methods inherited from class org.ametys.cms.search.query.AbstractDateOperatorQuery
build
Methods inherited from class org.ametys.cms.search.query.AbstractOperatorQuery
equals, getFieldName, getOperator, getValue, hashCode, rewrite, valueForQuery
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.ametys.cms.search.query.Query
buildAsJson, toString
-
Constructor Details
-
DateTimeQuery
Build a DateQuery testing the existence of the field.- Parameters:
fieldPath
- the field path.
-
DateTimeQuery
Build a DateQuery.- Parameters:
fieldPath
- the field's pathvalue
- the value.
-
DateTimeQuery
Build a DateQuery.- Parameters:
fieldPath
- the field's pathvalue
- the value.
-
DateTimeQuery
Build a DateQuery.- Parameters:
fieldPath
- the field's pathop
- the operator.value
- the value.
-
DateTimeQuery
Build a DateQuery.- Parameters:
fieldPath
- the field's pathop
- the operator.value
- the value.
-
-
Method Details
-
appendDateValue
Description copied from class:AbstractDateOperatorQuery
Format and append the given date to a StringBuilder.- Overrides:
appendDateValue
in classAbstractDateOperatorQuery
- Parameters:
query
- The string builder containing the query being built.operator
- The query operator.value
- The test value.
-