Interface UDFExecution


public interface UDFExecution
The execution of user-defined functions (UDFs) is carried out by this interface. It distinguishes the functions with respect to their return type and maps it to the corresponding Java-type (void, long, String,...).
  • Method Details

    • executeVoidFunction

      void executeVoidFunction(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the VOID-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.
    • executeIntegerFunction

      long executeIntegerFunction(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT and returns the resulting long value. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the INTEGER-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Returns:
      The return value as long.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.
    • executeFloatFunction

      double executeFloatFunction(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT and returns the resulting double value. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the FLOAT-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Returns:
      The return value as double.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.
    • executeBooleanFunction

      boolean executeBooleanFunction(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT and returns the resulting boolean value. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the BOOLEAN-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Returns:
      The return value as boolean.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.
    • executeStringFunction

      String executeStringFunction(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT and returns the resulting string. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the STRING-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Returns:
      The return value as string.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.
    • executeURIFunction

      URI executeURIFunction(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT and returns the resulting reference. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the URI-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Returns:
      The return value as URI.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.
    • executeUDTFunction

      UDTValue executeUDTFunction(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT and returns the resulting UDT-value. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the UDT-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Returns:
      The return value as UDT-value. The caller is responsible for closing.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.
    • executeUDTFunctionIncrementally

      ServerUDTInputStream executeUDTFunctionIncrementally(SessionToken session, UDTValue proxy, String functionName) throws UDFNotRegisteredException, UDFException
      Executes the designated user-defined function for the designated value of a UDT and returns the resulting UDT-value as ServerUDTInputStream. The function has to be registered for the UDT of the designated value, otherwise a UDFNotRegisteredException will be thrown. There may also be an exception caused by the execution of the UDF which is signalled by a UDFException.
      The server input stream does not provide the complete content of the underlying resource but a proxy object requesting the content incrementally when transfered via the communication.
      Parameters:
      session - The session which is used to check for access rights on this method.
      proxy - (A proxy for) the value of the UDT which the UDT-UDF is executed with. The caller is responsible for closing.
      functionName - The name of the UDF to execute for the designated UDT-value.
      Returns:
      The return value as ServerUDTInputStream, that is, clients do not retrieve all of the content of the stream at once but incrementally. The caller is responsible for closing.
      Throws:
      UDFNotRegisteredException - If the designated function is not registered for the user-defined data type of the designated value, an UDFNotRegisteredException will be raised.
      UDFException - If the executed user-defined function fails, the corresponding exceptions will be wrapped and propagated by a UDFException.