
org.hibernate.jpa.internal.schemagen.GenerationSourceFromScript Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hibernate-entitymanager
Show all versions of hibernate-entitymanager
A module of the Hibernate O/RM project
/*
* Hibernate, Relational Persistence for Idiomatic Java
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or .
*/
package org.hibernate.jpa.internal.schemagen;
import org.hibernate.tool.hbm2ddl.ImportSqlCommandExtractor;
/**
* Handles schema generation source from a "script"
*
* @author Steve Ebersole
*/
public class GenerationSourceFromScript implements GenerationSource {
private final ScriptSourceInput inputSource;
private final ImportSqlCommandExtractor scriptCommandExtractor;
public GenerationSourceFromScript(ScriptSourceInput inputSource, ImportSqlCommandExtractor scriptCommandExtractor) {
this.inputSource = inputSource;
this.scriptCommandExtractor = scriptCommandExtractor;
}
@Override
public Iterable getCommands() {
return inputSource.read( scriptCommandExtractor );
}
@Override
public void release() {
inputSource.release();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy