Class GenericLanguageFactory

java.lang.Object
org.apache.derby.impl.sql.GenericLanguageFactory
All Implemented Interfaces:
ModuleControl, LanguageFactory

public class GenericLanguageFactory extends Object implements LanguageFactory, ModuleControl
The LanguageFactory provides system-wide services that are available on the Database API.
  • Field Details

  • Constructor Details

    • GenericLanguageFactory

      public GenericLanguageFactory()
  • Method Details

    • boot

      public void boot(boolean create, Properties startParams) throws StandardException
      Start-up method for this instance of the language factory. This service is expected to be started and accessed relative to a database.
      Specified by:
      boot in interface ModuleControl
      Parameters:
      startParams - The start-up parameters (ignored in this case)
      Throws:
      StandardException - Thrown if module cannot be booted.
      See Also:
    • stop

      public void stop()
      Stop this module. In this case, nothing needs to be done.
      Specified by:
      stop in interface ModuleControl
      See Also:
    • newParameterValueSet

      public ParameterValueSet newParameterValueSet(ClassInspector ci, int numParms, boolean hasReturnParam)
      Factory method for getting a ParameterValueSet
      Specified by:
      newParameterValueSet in interface LanguageFactory
      Parameters:
      numParms - The number of parameters in the ParameterValueSet
      hasReturnParam - true if this parameter set has a return parameter. The return parameter is always the 1st parameter in the list. It is due to a callableStatement like this: ? = CALL myMethod()
      Returns:
      A new ParameterValueSet with the given number of parms
      See Also:
    • getResultDescription

      public ResultDescription getResultDescription(ResultDescription inputResultDescription, int[] theCols)
      Get a new result description from the input result description. Picks only the columns in the column array from the inputResultDescription.
      Specified by:
      getResultDescription in interface LanguageFactory
      Parameters:
      inputResultDescription - the input rd
      theCols - array of ints, non null
      Returns:
      ResultDescription the rd
    • getResultDescription

      public ResultDescription getResultDescription(ResultColumnDescriptor[] cols, String type)
      Get a new result description
      Specified by:
      getResultDescription in interface LanguageFactory
      Parameters:
      cols - an array of col descriptors
      type - the statement type
      Returns:
      ResultDescription the rd
    • findServiceModule

      private static Object findServiceModule(Object serviceModule, String factoryInterface) throws StandardException
      Privileged startup. Must be private so that user code can't call this entry point.
      Throws:
      StandardException