Class UnresolvedFunctionException

All Implemented Interfaces:
Serializable

public class UnresolvedFunctionException extends ParseException
Exception thrown when a function can not be resolved by the library.
Since:
1.3
Version:
1.4 (08/2015)
Author:
Grégory Mantelet (ARI)
See Also:
  • Field Details

    • functionInError

      protected final ADQLFunction functionInError
      Function which can not be resolved.
  • Constructor Details

    • UnresolvedFunctionException

      public UnresolvedFunctionException(String message)
      Build the exception with just a message.
      Parameters:
      message - Description of the error.
    • UnresolvedFunctionException

      public UnresolvedFunctionException(String message, TextPosition pos)
      Build the exception with just a message.
      Parameters:
      message - Description of the error.
      pos - Position of the unresolved function inside the ADQL query.
      Since:
      1.4
    • UnresolvedFunctionException

      public UnresolvedFunctionException(ADQLFunction fct)
      Build the exception with the unresolved function in parameter. The position of this function in the ADQL query can be retrieved and used afterwards.
      Parameters:
      fct - The unresolved function.
    • UnresolvedFunctionException

      public UnresolvedFunctionException(String message, ADQLFunction fct)
      Build the exception with a message but also with the unresolved function in parameter. The position of this function in the ADQL query can be retrieved and used afterwards.
      Parameters:
      message - Description of the error.
      fct - The unresolved function.
  • Method Details

    • getFunction

      public final ADQLFunction getFunction()
      Get the unresolved function at the origin of this exception.
      Returns:
      The unresolved function. Note: MAY be NULL
    • getFctSignature

      public static String getFctSignature(ADQLFunction fct)

      Get the signature of the function given in parameter.

      In this signature, just the name and the type of all the parameters are written. The return type is never part of a function signature.

      Note 1: A parameter type can be either "NUMERIC", "STRING" or "GEOMETRY". In order to be the most generic has possible, no more precision about a type is returned here. If the parameter is none of these type kinds, "param" suffixed by the parameter index (e.g. "param1") is returned.

      Note 2: If the given object is NULL, an empty string is returned.

      Parameters:
      fct - Function whose the signature must be returned.
      Returns:
      The corresponding signature.