}
} else if (newDescriptor instanceof ResourceEnvRef) {
ResourceEnvRef resourceEnvRef = (ResourceEnvRef)newDescriptor;
descriptor.getSunDescriptor().addResourceEnvRef(resourceEnvRef);
try {
JmsDestinationReferenceDescriptor rrd = descriptor.getJmsDestinationReferenceByName(resourceEnvRef.getResourceEnvRefName());
rrd.setJndiName(resourceEnvRef.getJndiName());
} catch (IllegalArgumentException iae) {
DOLUtils.getDefaultLogger().warning(iae.getMessage());
}
} else if (newDescriptor instanceof EjbRef) {
EjbRef ejbRef = (EjbRef) newDescriptor;