Package adql.query.constraint
Class IsNull
java.lang.Object
adql.query.constraint.IsNull
- All Implemented Interfaces:
ADQLObject,ADQLConstraint
Represents a comparison between a column to the NULL value.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionBuilds a IsNull constraint by copying the given one.IsNull(ADQLColumn column) Builds a comparison between the given column and NULL.IsNull(ADQLColumn column, boolean isNot) Builds a comparison between the column and NULL. -
Method Summary
Modifier and TypeMethodDescriptionGets an iterator on the intern ADQL objects.final ADQLColumnGets the column whose the value is compared to NULL.getCopy()Gets a (deep) copy of this ADQL object.final LanguageFeatureGet the description of this ADQL's Language Feature.getName()Gets the name of this object in ADQL.final TextPositionGets the position of this object/token in the ADQL query.final booleanTells whether the predicate is IS NULL or IS NOT NULL.final voidsetColumn(ADQLColumn column) Lets changing the column whose the value must be compared to NULL.final voidsetNotNull(boolean notNull) Lets indicating which predicate must be used (IS NULL or IS NOT NULL).final voidsetPosition(TextPosition position) Set the position of thisIsNullin the given ADQL query string.toADQL()Gets the ADQL expression of this object.
-
Field Details
-
FEATURE
Description of this ADQL Feature.- Since:
- 2.0
-
-
Constructor Details
-
IsNull
Builds a comparison between the given column and NULL.- Parameters:
column- The column whose the value must be compared to NULL.- Throws:
NullPointerException- If the given column is NULL.
-
IsNull
Builds a comparison between the column and NULL.- Parameters:
column- The column whose the value must be compared to NULL.isNot-truemeans IS NOT NULL,falsemeans IS NULL.- Throws:
NullPointerException- If the given column is NULL.
-
IsNull
Builds a IsNull constraint by copying the given one.- Parameters:
toCopy- The IsNull to copy.- Throws:
Exception- If there is an error during the copy.
-
-
Method Details
-
getFeatureDescription
Description copied from interface:ADQLObjectGet the description of this ADQL's Language Feature.Note: Getting this description is generally only useful when discovery optional features so that determining if they are allowed to be used in ADQL queries.
- Specified by:
getFeatureDescriptionin interfaceADQLObject- Returns:
- Description of this ADQL object as an ADQL's feature.
-
getColumn
Gets the column whose the value is compared to NULL.- Returns:
- The column compared to NULL.
-
setColumn
Lets changing the column whose the value must be compared to NULL.- Parameters:
column- The new column to compare to NULL.- Throws:
NullPointerException- If the given column is NULL.
-
isNotNull
public final boolean isNotNull()Tells whether the predicate is IS NULL or IS NOT NULL.- Returns:
truefor IS NOT NULL,falsefor IS NULL.
-
setNotNull
public final void setNotNull(boolean notNull) Lets indicating which predicate must be used (IS NULL or IS NOT NULL).- Parameters:
notNull-truefor IS NOT NULL,falsefor IS NULL.
-
getPosition
Description copied from interface:ADQLObjectGets the position of this object/token in the ADQL query.By default, no position should be set.
- Specified by:
getPositionin interfaceADQLObject- Returns:
- Position of this ADQL item in the ADQL query, or NULL if not written originally in the query (for example, if added afterwards).
-
setPosition
Set the position of thisIsNullin the given ADQL query string.- Parameters:
position- New position of thisIsNull.- Since:
- 1.4
-
getCopy
Description copied from interface:ADQLObjectGets a (deep) copy of this ADQL object.- Specified by:
getCopyin interfaceADQLObject- Returns:
- The copy of this ADQL object.
- Throws:
Exception- If there is any error during the copy.
-
getName
Description copied from interface:ADQLObjectGets the name of this object in ADQL.- Specified by:
getNamein interfaceADQLObject- Returns:
- The name of this ADQL object.
-
adqlIterator
Description copied from interface:ADQLObjectGets an iterator on the intern ADQL objects.Note: The returned iterator is particularly used by a
ISearchHandlerextension to browse a whole ADQL tree.- Specified by:
adqlIteratorin interfaceADQLObject- Returns:
- An ADQL objects iterator.
- See Also:
-
toADQL
Description copied from interface:ADQLObjectGets the ADQL expression of this object.- Specified by:
toADQLin interfaceADQLObject- Returns:
- The corresponding ADQL expression.
-