// Path: RocLang/robotcontrol.parent/robotcontrol/xtend-gen/robotcontrol/RocRuntimeModule.java
// @SuppressWarnings("all")
// public class RocRuntimeModule extends AbstractRocRuntimeModule {
// }
// 
// Path: RocLang/robotcontrol.parent/robotcontrol/xtend-gen/robotcontrol/RocStandaloneSetup.java
// @SuppressWarnings("all")
// public class RocStandaloneSetup extends RocStandaloneSetupGenerated {
//   public static void doSetup() {
//     RocStandaloneSetup _rocStandaloneSetup = new RocStandaloneSetup();
//     _rocStandaloneSetup.createInjectorAndDoEMFRegistration();
//   }
// }


import com.google.inject.Guice;
import com.google.inject.Injector;
import org.eclipse.xtext.junit4.GlobalRegistries;
import org.eclipse.xtext.junit4.GlobalRegistries.GlobalStateMemento;
import org.eclipse.xtext.junit4.IInjectorProvider;
import org.eclipse.xtext.junit4.IRegistryConfigurator;
import robotcontrol.RocRuntimeModule;
import robotcontrol.RocStandaloneSetup;
/*
 * generated by Xtext 2.10.0
 */
package robotcontrol.tests;


public class RocInjectorProvider implements IInjectorProvider, IRegistryConfigurator {

	protected GlobalStateMemento stateBeforeInjectorCreation;
	protected GlobalStateMemento stateAfterInjectorCreation;
	protected Injector injector;

	static {
		GlobalRegistries.initializeDefaults();
	}

	@Override
	public Injector getInjector() {
		if (injector == null) {
			stateBeforeInjectorCreation = GlobalRegistries.makeCopyOfGlobalState();
			this.injector = internalCreateInjector();
			stateAfterInjectorCreation = GlobalRegistries.makeCopyOfGlobalState();
		}
		return injector;
	}

	protected Injector internalCreateInjector() {
		return new RocStandaloneSetup() {
			@Override
			public Injector createInjector() {
				return Guice.createInjector(createRuntimeModule());
			}
		}.createInjectorAndDoEMFRegistration();
	}

// Path: RocLang/robotcontrol.parent/robotcontrol/xtend-gen/robotcontrol/RocRuntimeModule.java
// @SuppressWarnings("all")
// public class RocRuntimeModule extends AbstractRocRuntimeModule {
// }
// 
// Path: RocLang/robotcontrol.parent/robotcontrol/xtend-gen/robotcontrol/RocStandaloneSetup.java
// @SuppressWarnings("all")
// public class RocStandaloneSetup extends RocStandaloneSetupGenerated {
//   public static void doSetup() {
//     RocStandaloneSetup _rocStandaloneSetup = new RocStandaloneSetup();
//     _rocStandaloneSetup.createInjectorAndDoEMFRegistration();
//   }
// }


// Path: RocLang/robotcontrol.parent/robotcontrol.tests/src-gen/robotcontrol/tests/RocInjectorProvider.java
import com.google.inject.Guice;
import com.google.inject.Injector;
import org.eclipse.xtext.junit4.GlobalRegistries;
import org.eclipse.xtext.junit4.GlobalRegistries.GlobalStateMemento;
import org.eclipse.xtext.junit4.IInjectorProvider;
import org.eclipse.xtext.junit4.IRegistryConfigurator;
import robotcontrol.RocRuntimeModule;
import robotcontrol.RocStandaloneSetup;

/*
 * generated by Xtext 2.10.0
 */
package robotcontrol.tests;


public class RocInjectorProvider implements IInjectorProvider, IRegistryConfigurator {

	protected GlobalStateMemento stateBeforeInjectorCreation;
	protected GlobalStateMemento stateAfterInjectorCreation;
	protected Injector injector;

	static {
		GlobalRegistries.initializeDefaults();
	}

	@Override
	public Injector getInjector() {
		if (injector == null) {
			stateBeforeInjectorCreation = GlobalRegistries.makeCopyOfGlobalState();
			this.injector = internalCreateInjector();
			stateAfterInjectorCreation = GlobalRegistries.makeCopyOfGlobalState();
		}
		return injector;
	}

	protected Injector internalCreateInjector() {
		return new RocStandaloneSetup() {
			@Override
			public Injector createInjector() {
				return Guice.createInjector(createRuntimeModule());
			}
		}.createInjectorAndDoEMFRegistration();
	}

	protected RocRuntimeModule createRuntimeModule() {