Package com.io7m.cedarbridge.schema.compiler

# Class CBSchemaCompilerFactory

java.lang.Object
com.io7m.cedarbridge.schema.compiler.CBSchemaCompilerFactory

All Implemented Interfaces:
  `CBSchemaCompilerFactoryType`

public final class CBSchemaCompilerFactory extends Object implements CBSchemaCompilerFactoryType
A factory of schema compilers.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `CBSchemaCompilerFactory()`
  A factory of schema compilers.
  `CBSchemaCompilerFactory(CBExpressionSourceFactoryType inSources, CBParserFactoryType inParsers, CBBinderFactoryType inBinders, CBTypeCheckerFactoryType inTypers)`
  A factory of schema compilers.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `CBSchemaCompilerType`
  `createCompiler(CBSchemaCompilerConfiguration configuration)`
  Create a compiler for the given configuration.
  `CBSchemaCompilerType`
  `createCompiler(CBSchemaCompilerConfiguration configuration, Consumer<CBError> errorConsumer)`
  Create a compiler for the given configuration.

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

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

- ## Constructor Details

  - ### CBSchemaCompilerFactory

    public CBSchemaCompilerFactory()
    A factory of schema compilers. Dependencies are loaded from ServiceLoader.

  - ### CBSchemaCompilerFactory

    public CBSchemaCompilerFactory(CBExpressionSourceFactoryType inSources, CBParserFactoryType inParsers, CBBinderFactoryType inBinders, CBTypeCheckerFactoryType inTypers)
    A factory of schema compilers.
    Parameters:
      `inBinders` - A source of binders
      `inParsers` - A source of parsers
      `inSources` - A source of expression sources
      `inTypers` - A source of type checkers

- ## Method Details

  - ### createCompiler

    public CBSchemaCompilerType createCompiler(CBSchemaCompilerConfiguration configuration)
    Description copied from interface: `CBSchemaCompilerFactoryType`
    Create a compiler for the given configuration.
    Specified by:
      `createCompiler` in interface `CBSchemaCompilerFactoryType`
    Parameters:
      `configuration` - The compiler configuration
    Returns:
      A new compiler

  - ### createCompiler

    public CBSchemaCompilerType createCompiler(CBSchemaCompilerConfiguration configuration, Consumer<CBError> errorConsumer)
    Description copied from interface: `CBSchemaCompilerFactoryType`
    Create a compiler for the given configuration.
    Specified by:
      `createCompiler` in interface `CBSchemaCompilerFactoryType`
    Parameters:
      `configuration` - The compiler configuration
      `errorConsumer` - An error consumer function
    Returns:
      A new compiler