Interface UnboundProcedure

All Superinterfaces:
Procedure

@Evolving public interface UnboundProcedure extends Procedure
A procedure that is not bound to input types.
Since:
4.0.0
  • Method Summary

    Modifier and Type
    Method
    Description
    bind(StructType inputType)
    Binds this procedure to input types.

    Methods inherited from interface org.apache.spark.sql.connector.catalog.procedures.Procedure

    description, name
  • Method Details

    • bind

      BoundProcedure bind(StructType inputType)
      Binds this procedure to input types.

      If the catalog supports procedure overloading, the implementation is expected to pick the best matching version of the procedure. If overloading is not supported, the implementation can validate if the input types are compatible while binding or delegate that to Spark. Regardless, Spark will always perform the final validation of the arguments and rearrange them as needed based on reported parameters.

      The provided inputType is based on the procedure arguments. If an argument is passed by name, its metadata will indicate this with ProcedureParameter.BY_NAME_METADATA_KEY set to true. In such cases, the field name will match the name of the target procedure parameter. If the argument is not named, ProcedureParameter.BY_NAME_METADATA_KEY will not be set and the name will be assigned randomly.

      Parameters:
      inputType - the input types to bind to
      Returns:
      the bound procedure that is most suitable for the given input types