resourceReferences.add(resourceReference);
JBossRemoteEnvironmentRefsGroupMetaData xml = new JBossRemoteEnvironmentRefsGroupMetaData();
xml.setResourceReferences(resourceReferences);
DummyInjectionContainer container = new DummyInjectionContainer(enc);
ResourceHandler<RemoteEnvironment> handler = new ResourceHandler<RemoteEnvironment>();
Collection<InjectionHandler<RemoteEnvironment>> handlers = new HashSet<InjectionHandler<RemoteEnvironment>>();
handlers.add(handler);
for(InjectionHandler<RemoteEnvironment> h : handlers) h.loadXml(xml, container);
Map<AccessibleObject, Injector> tmp = InjectionUtil.processAnnotations(container, handlers, MyClass.class);
for(EncInjector encInjector : container.getEncInjectors().values())
encInjector.inject(container);
MyClass instance = new MyClass();
for(Injector injector : tmp.values())