org.hibernate.bytecode.internal.BytecodeProviderInitiator Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hibernate-core Show documentation
Show all versions of hibernate-core Show documentation
Hibernate's core ORM functionality
/*
* 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.bytecode.internal;
import java.util.Map;
import org.hibernate.boot.registry.StandardServiceInitiator;
import org.hibernate.bytecode.spi.BytecodeProvider;
import org.hibernate.cfg.Environment;
import org.hibernate.service.spi.ServiceRegistryImplementor;
public final class BytecodeProviderInitiator implements StandardServiceInitiator {
/**
* Singleton access
*/
public static final StandardServiceInitiator INSTANCE = new BytecodeProviderInitiator();
@Override
public BytecodeProvider initiateService(Map configurationValues, ServiceRegistryImplementor registry) {
// TODO in 6 this will no longer use Environment, which is configured via global environment variables,
// but move to a component which can be reconfigured differently in each registry.
return Environment.getBytecodeProvider();
}
@Override
public Class getServiceInitiated() {
return BytecodeProvider.class;
}
}