if (knownResourceEnvTypes.contains(type.getName())) {
/*
* @Resource <resource-env-ref>
*/
ResourceEnvRef resourceEnvRef = consumer.getResourceEnvRefMap().get(refName);
if (resourceEnvRef == null) {
resourceEnvRef = new ResourceEnvRef();
resourceEnvRef.setName(refName);
consumer.getResourceEnvRef().add(resourceEnvRef);
}
if (resourceEnvRef.getResourceEnvRefType() == null || ("").equals(resourceEnvRef.getResourceEnvRefType())) {
resourceEnvRef.setResourceEnvRefType(type.getName());
}
reference = resourceEnvRef;
} else if (isKnownEnvironmentEntryType(type)) {
/*
* @Resource <env-entry>