All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.hibernate.bytecode.internal.BytecodeProviderInitiator Maven / Gradle / Ivy

There is a newer version: 7.0.0.Alpha1
Show newest version
/*
 * 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;
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy