Package adql.db.exception

## Class UnresolvedFunctionException

- java.lang.Object
- - java.lang.Throwable
  - - java.lang.Exception
    - - adql.parser.ParseException
      - - adql.db.exception.UnresolvedFunctionException

- All Implemented Interfaces:
    `java.io.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:
    Serialized Form

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `protected ADQLFunction` | `functionInError` | Function which can not be resolved.

    - ### Fields inherited from class adql.parser.ParseException

      `currentToken, eol, expectedTokenSequences, position, tokenImage`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `UnresolvedFunctionException​(ADQLFunction fct)` | Build the exception with the unresolved function in parameter.
    `UnresolvedFunctionException​(java.lang.String message)` | Build the exception with just a message.
    `UnresolvedFunctionException​(java.lang.String message, ADQLFunction fct)` | Build the exception with a message but also with the unresolved function in parameter.
    `UnresolvedFunctionException​(java.lang.String message, TextPosition pos)` | Build the exception with just a message.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `static java.lang.String` | `getFctSignature​(ADQLFunction fct)` | Get the signature of the function given in parameter.
    `ADQLFunction` | `getFunction()` | Get the unresolved function at the origin of this exception.

    - ### Methods inherited from class adql.parser.ParseException

      `getPosition`

    - ### Methods inherited from class java.lang.Throwable

      `addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### functionInError

          protected final ADQLFunction functionInError

      Function which can not be resolved.

  - ### Constructor Detail

    - #### UnresolvedFunctionException

          public UnresolvedFunctionException​(java.lang.String message)

      Build the exception with just a message.
      Parameters:
        `message` - Description of the error.

    - #### UnresolvedFunctionException

          public UnresolvedFunctionException​(java.lang.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​(java.lang.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 Detail

    - #### 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 java.lang.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.