Skip to content
Snippets Groups Projects
Select Git revision
  • 1986ed0e61420852edb4d8cb455ca13f3b142089
  • master default protected
  • ia2
  • adql2.1-ia2
  • private_rows
5 results

ADQLOperand.java

Blame
    • gmantele's avatar
      496e769c
      [ADQL,TAP] Add STC-S and UDFs support in the ADQL parser. Now, it is possible... · 496e769c
      gmantele authored
      [ADQL,TAP] Add STC-S and UDFs support in the ADQL parser. Now, it is possible to provide a list of allowed UDFs, regions and coordinate systems. The ServiceConnection of TAP is now able to provide these lists and to propagate them to the ADQLExecutor. UDFs and allowed regions are now listed automatically in the /capabilities resource of TAP. The type 'geometry' is now fully supported in ADQL. That's why the new function 'isGeometry()' has been added to all ADQLOperand extensions. Now the DBChecker is also able to check roughly types of columns and UDFs (unknown when parsing syntactically a query). The syntax of STC-S regions (expressed in the REGION function) are now checked by DBChecker. However, for the moment, geometries are not serialized in STC-S in the output....but it should be possible in some way in the next commit(s).
      496e769c
      History
      [ADQL,TAP] Add STC-S and UDFs support in the ADQL parser. Now, it is possible...
      gmantele authored
      [ADQL,TAP] Add STC-S and UDFs support in the ADQL parser. Now, it is possible to provide a list of allowed UDFs, regions and coordinate systems. The ServiceConnection of TAP is now able to provide these lists and to propagate them to the ADQLExecutor. UDFs and allowed regions are now listed automatically in the /capabilities resource of TAP. The type 'geometry' is now fully supported in ADQL. That's why the new function 'isGeometry()' has been added to all ADQLOperand extensions. Now the DBChecker is also able to check roughly types of columns and UDFs (unknown when parsing syntactically a query). The syntax of STC-S regions (expressed in the REGION function) are now checked by DBChecker. However, for the moment, geometries are not serialized in STC-S in the output....but it should be possible in some way in the next commit(s).
    ADQLOperand.java 1.78 KiB
    package adql.query.operand;
    
    /*
     * This file is part of ADQLLibrary.
     * 
     * ADQLLibrary is free software: you can redistribute it and/or modify
     * it under the terms of the GNU Lesser General Public License as published by
     * the Free Software Foundation, either version 3 of the License, or
     * (at your option) any later version.
     * 
     * ADQLLibrary is distributed in the hope that it will be useful,
     * but WITHOUT ANY WARRANTY; without even the implied warranty of
     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     * GNU Lesser General Public License for more details.
     * 
     * You should have received a copy of the GNU Lesser General Public License
     * along with ADQLLibrary.  If not, see <http://www.gnu.org/licenses/>.
     * 
     * Copyright 2012,2014 - UDS/Centre de Données astronomiques de Strasbourg (CDS),
     *                       Astronomisches Rechen Institut (ARI)
     */
    
    import adql.query.ADQLObject;
    
    /**
     * <p>Any ADQL operand (an operation, a constant, a column name, a function, ...) must implement this interface
     * and indicates whether it corresponds to a numeric, a string or a geometrical region value.</p>
     * 
     * @author Gr&eacute;gory Mantelet (CDS;ARI)
     * @version 1.3 (10/2014)
     */
    public interface ADQLOperand extends ADQLObject {
    
    	/**
    	 * Tell whether this operand is numeric or not.
    	 * 
    	 * @return	<i>true</i> if this operand is numeric, <i>false</i> otherwise.
    	 */
    	public boolean isNumeric();
    
    	/**
    	 * Tell whether this operand is a string or not.
    	 * 
    	 * @return	<i>true</i> if this operand is a string, <i>false</i> otherwise.
    	 */
    	public boolean isString();
    
    	/**
    	 * Tell whether this operand is a geometrical region or not.
    	 * 
    	 * @return	<i>true</i> if this operand is a geometry, <i>false</i> otherwise.
    	 * 
    	 * @since 1.3
    	 */
    	public boolean isGeometry();
    
    }