Class Registry

java.lang.Object
org.apache.sis.internal.filter.sqlmm.Registry
All Implemented Interfaces:
FunctionRegister

public final class Registry extends Object implements FunctionRegister
Since:
1.1
Version:
1.1
  • Field Details

    • library

      private final Geometries<?> library
      The geometry library used by this registry.
  • Constructor Details

    • Registry

      public Registry(Geometries<?> library)
      Creates the default register.
      Parameters:
      library - the geometry library to use.
  • Method Details

    • getAuthority

      public String getAuthority()
      Returns the name of the standard or authority defining the functions.
      Specified by:
      getAuthority in interface FunctionRegister
      Returns:
      provider of function definitions.
    • getNames

      public Collection<String> getNames()
      Returns the names of all functions known to this register.
      Specified by:
      getNames in interface FunctionRegister
      Returns:
      set of supported function names.
    • create

      public <R> Expression<R,?> create(String name, Expression<? super R,?>[] parameters)
      Create a new function of the given name with given parameters. It is caller's responsibility to ensure that the given array is non-null, has been cloned and does not contain null elements. This method verifies only the number of parameters.
      Specified by:
      create in interface FunctionRegister
      Type Parameters:
      R - the type of resources (e.g. Feature) used as inputs.
      Parameters:
      name - name of the function to call.
      parameters - expressions providing values for the function arguments.
      Returns:
      an expression which will call the specified function.
      Throws:
      IllegalArgumentException - if function name is unknown or some parameters are illegal.