Top Description Inners Fields Constructors Methods
org.jooq.impl

pack-priv final Class TranslatingMetaProvider

extends Object
implements MetaProvider
Class Inheritance
All Implemented Interfaces
org.jooq.MetaProvider
Static Imports
org.jooq.VisitListener.onVisitStart, org.jooq.impl.DSL.name, .Tools.configuration

MetaProvider implementation which can provide a Meta implementation based on a set of DDL scripts as the input.
Author
Knut Wannheden

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv class

Field Summary

Modifier and TypeField and Description
private final Configuration
private static final JooqLogger
private static final Pattern
private final Source[]

Constructor Summary

AccessConstructor and Description
public
TranslatingMetaProvider(Configuration configuration, Source... scripts)

Method Summary

Modifier and TypeMethod and Description
public Meta
provide()

Implements org.jooq.MetaProvider.provide.

Provide meta data information.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

configurationback to summary
private final Configuration configuration
logback to summary
private static final JooqLogger log
P_NAMEback to summary
private static final Pattern P_NAME
scriptsback to summary
private final Source[] scripts

Constructor Detail

TranslatingMetaProviderback to summary
public TranslatingMetaProvider(Configuration configuration, Source... scripts)

Method Detail

provideback to summary
public Meta provide()

Implements org.jooq.MetaProvider.provide.

Doc from org.jooq.MetaProvider.provide.

Provide meta data information.

Annotations
@Override
org.jooq.impl back to summary

pack-priv final Class TranslatingMetaProvider.DDLDatabaseInitializer

extends Object
implements AutoCloseable
Class Inheritance
All Implemented Interfaces
java.lang.AutoCloseable

Field Summary

Modifier and TypeField and Description
private Connection
private DSLContext

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public void
close()

Implements java.lang.AutoCloseable.close.

Closes this resource, relinquishing any underlying resources.
private final void
loadScript(Source source)

Parses and executes the script represented by reader against the H2 database.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

connectionback to summary
private Connection connection
ctxback to summary
private DSLContext ctx

Constructor Detail

DDLDatabaseInitializerback to summary
private DDLDatabaseInitializer()

Method Detail

closeback to summary
public void close()

Implements java.lang.AutoCloseable.close.

Doc from java.lang.AutoCloseable.close.

Closes this resource, relinquishing any underlying resources. This method is invoked automatically on objects managed by the try-with-resources statement.

Annotations
@Override
loadScriptback to summary
private final void loadScript(Source source)

Parses and executes the script represented by reader against the H2 database. If the script references a schema which doesn't exist, it will be automatically created first.

Any parser errors will be thrown. It is however possible to delimit sections which cannot be parsed using special comments.

See Also
Settings#getParseIgnoreCommentStart(), Settings#getParseIgnoreCommentStop()