if (adminObject == null) {
throw new DeploymentException("No admin object declared for interface: " + adminObjectInterface);
}
for (int j = 0; j < gerAdminObject.getAdminobjectInstanceArray().length; j++) {
GerAdminobjectInstanceType gerAdminObjectInstance = gerAdminObject.getAdminobjectInstanceArray()[j];
// create the adminObjectGBean
GBeanInfoFactory adminObjectInfoFactory = new GBeanInfoFactory("org.apache.geronimo.connector.AdminObjectWrapper", cl);
ConfigProperty[] configProperties = getConfigProperties(adminObject.getConfigPropertyArray(), gerAdminObjectInstance.getConfigPropertySettingArray());
GBeanMBean adminObjectGBean = setUpDynamicGBean(adminObjectInfoFactory, configProperties, cl);
// set the standard properties
try {
adminObjectGBean.setAttribute("adminObjectInterface", cl.loadClass(adminObjectInterface));
adminObjectGBean.setAttribute("adminObjectClass", cl.loadClass(adminObject.getAdminobjectClass().getStringValue()));
} catch (Exception e) {
throw new DeploymentException("Could not initialize AdminObject", e);
}
// add it
try {
Properties nameProps = new Properties();
nameProps.put("j2eeType", "JCAAdminObject");
nameProps.put("name", gerAdminObjectInstance.getMessageDestinationName());
nameProps.put("J2EEServer", earContext.getJ2EEServerName());
ObjectName adminObjectObjectName = new ObjectName(earContext.getJ2EEDomainName(), nameProps);
earContext.addGBean(adminObjectObjectName, adminObjectGBean);
} catch (MalformedObjectNameException e) {