Package

slick

codegen

Permalink

package codegen

Code generator / type providers

Source
package.scala
Linear Supertypes
AnyRef, Any
Content Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. codegen
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. abstract class AbstractGenerator[Code, TermName, TypeName] extends GeneratorHelpers[Code, TermName, TypeName]

    Permalink

    Slick code generator providing the base structure and facilities.

    Slick code generator providing the base structure and facilities. It contains a subclass as a generator for Tables, which again contains subclasses for Column, etc. The implementation follows the virtual class pattern, which allows flexible customization by overriding the inner classes (following the pattern).

    See also

    http://lampwww.epfl.ch/~odersky/papers/ScalableComponent.html

  2. abstract class AbstractSourceCodeGenerator extends AbstractGenerator[String, String, String] with StringGeneratorHelpers

    Permalink

    Base implementation for a Source code String generator

  3. trait GeneratorHelpers[Code, TermName, TypeName] extends AnyRef

    Permalink

    Helper methods for code generation

  4. trait OutputHelpers extends AnyRef

    Permalink

    Output-related code-generation utilities.

  5. class SourceCodeGenerator extends AbstractSourceCodeGenerator with OutputHelpers

    Permalink

    A customizable code generator for working with Slick.

    A customizable code generator for working with Slick.

    For usage information please see the corresponding part of the Slick documentation.

    The implementation is structured into a small hierarchy of sub-generators responsible for different fragments of the complete output. The implementation of each sub-generator can be swapped out for a customized one by overriding the corresponding factory method. SourceCodeGenerator contains a factory method Table, which it uses to generate a sub-generator for each table. The sub-generator Table in turn contains sub-generators for Table classes, entity case classes, columns, key, indices, etc. Custom sub-generators can easily be added as well.

    Within the sub-generators the relevant part of the Slick data model can be accessed to drive the code generation.

    Of coures it makes sense to integrate this into your build process.

  6. trait StringGeneratorHelpers extends GeneratorHelpers[String, String, String]

    Permalink

Value Members

  1. object SourceCodeGenerator

    Permalink

    A runnable class to execute the code generator without further setup

Inherited from AnyRef

Inherited from Any

Ungrouped