Examples of AdminObjectInstance


Examples of org.apache.geronimo.connector.deployment.jsr88.AdminObjectInstance

                        AdminObjectDCB adminDCB = adminDCBs[j];
                        if(adminDCB.getAdminObjectInterface().equals(providerData.getAdminObjectInterface())) {
                            AdminObjectInstance[] before = adminDCB.getAdminObjectInstance();
                            AdminObjectInstance[] after = new AdminObjectInstance[before.length+1];
                            System.arraycopy(before, 0, after, 0, before.length);
                            AdminObjectInstance instance = new AdminObjectInstance();
                            after[before.length] = instance;
                            adminDCB.setAdminObjectInstance(after);
                            instance.setMessageDestinationName(admin.getName());
                            for (Iterator it = admin.instanceProps.entrySet().iterator(); it.hasNext();) {
                                Map.Entry entry = (Map.Entry) it.next();
                                String name = getPropertyName((String)entry.getKey(), providerData.getConfigProperties());
                                for(int k=0; k<instance.getConfigPropertySetting().length; k++) {
                                    if(instance.getConfigPropertySetting(k).getName().equals(name)) {
                                        instance.getConfigPropertySetting(k).setValue((String)entry.getValue());
                                        break;
                                    }
                                }
                            }
                            break;
View Full Code Here

Examples of org.apache.geronimo.connector.deployment.jsr88.AdminObjectInstance

                        AdminObjectDCB adminDCB = adminDCBs[j];
                        if(adminDCB.getAdminObjectInterface().equals(providerData.getAdminObjectInterface())) {
                            AdminObjectInstance[] before = adminDCB.getAdminObjectInstance();
                            AdminObjectInstance[] after = new AdminObjectInstance[before.length+1];
                            System.arraycopy(before, 0, after, 0, before.length);
                            AdminObjectInstance instance = new AdminObjectInstance();
                            after[before.length] = instance;
                            adminDCB.setAdminObjectInstance(after);
                            instance.setMessageDestinationName(admin.getName());
                            for (Iterator it = admin.instanceProps.entrySet().iterator(); it.hasNext();) {
                                Map.Entry entry = (Map.Entry) it.next();
                                String name = getPropertyName((String)entry.getKey(), providerData.getConfigProperties());
                                for(int k=0; k<instance.getConfigPropertySetting().length; k++) {
                                    if(instance.getConfigPropertySetting(k).getName().equals(name)) {
                                        instance.getConfigPropertySetting(k).setValue((String)entry.getValue());
                                        break;
                                    }
                                }
                            }
                            break;
View Full Code Here

Examples of org.apache.geronimo.connector.deployment.jsr88.AdminObjectInstance

                        AdminObjectDCB adminDCB = adminDCBs[j];
                        if(adminDCB.getAdminObjectInterface().equals(providerData.getAdminObjectInterface())) {
                            AdminObjectInstance[] before = adminDCB.getAdminObjectInstance();
                            AdminObjectInstance[] after = new AdminObjectInstance[before.length+1];
                            System.arraycopy(before, 0, after, 0, before.length);
                            AdminObjectInstance instance = new AdminObjectInstance();
                            after[before.length] = instance;
                            adminDCB.setAdminObjectInstance(after);
                            instance.setMessageDestinationName(admin.getName());
                            for (Iterator it = admin.instanceProps.entrySet().iterator(); it.hasNext();) {
                                Map.Entry entry = (Map.Entry) it.next();
                                String name = getPropertyName((String)entry.getKey(), providerData.getConfigProperties());
                                for(int k=0; k<instance.getConfigPropertySetting().length; k++) {
                                    if(instance.getConfigPropertySetting(k).getName().equals(name)) {
                                        instance.getConfigPropertySetting(k).setValue((String)entry.getValue());
                                        break;
                                    }
                                }
                            }
                            break;
View Full Code Here

Examples of org.apache.geronimo.jee.connector.AdminobjectInstance

        resource.setInternalRar("resource-internalrar");
        Connector connector = connectorFactory.createConnector();
        Adminobject adminobject = connectorFactory.createAdminobject();
        adminobject.setAdminobjectClass("resource-connector-adminobject-adminobjectclass");
        adminobject.setAdminobjectInterface("resource-connector-adminobject-adminobjectinterface");
        AdminobjectInstance adminobjectInstance = connectorFactory.createAdminobjectInstance();
        adminobjectInstance.setMessageDestinationName("resource-connector-adminobject-instance-messagedestinationname");
        ConfigPropertySetting configPropertySetting = connectorFactory.createConfigPropertySetting();
        configPropertySetting.setName("resource-connector-adminobject-instance-name");
        configPropertySetting.setValue("resource-connector-adminobject-instance-value");
        adminobjectInstance.getConfigPropertySetting().add(configPropertySetting);
        adminobject.getAdminobjectInstance().add(adminobjectInstance);
        connector.getAdminobject().add(adminobject);
        environment = deploymentFactory.createEnvironment();
        artifact = deploymentFactory.createArtifact();
        artifact.setGroupId("org.apache.geronimo.testsuite");
View Full Code Here

Examples of org.apache.geronimo.jee.connector.AdminobjectInstance

        }
        else if (element.getText().equals(elementTypes[ADMIN_OBJECT_INSTANCE])) {
            if (isEmpty(textList.get(0).getText())) {
                return false;
            }
            AdminobjectInstance aoInstance = (AdminobjectInstance)eObject;
            if (aoInstance == null) {
                aoInstance = (AdminobjectInstance)getEFactory().create(AdminobjectInstance.class);
                admin = (Adminobject)((AdminObjectSection)section).getSelectedObject();
                admin.getAdminobjectInstance().add(aoInstance);
            }
            aoInstance.setMessageDestinationName(textList.get(0).getText());
        }
        else if (element.getText().equals(elementTypes[CONFIG_PROPERTY_SETTING])) {
            if (isEmpty(textList.get(0).getText()) || isEmpty(textList.get(1).getText())) {
                return false;
            }
            ConfigPropertySetting property = (ConfigPropertySetting)eObject;
            if (property == null) {
                property = (ConfigPropertySetting)getEFactory().create(ConfigPropertySetting.class);
                AdminobjectInstance aoInstance = (AdminobjectInstance)((AdminObjectSection)section).getSelectedObject();
                aoInstance.getConfigPropertySetting().add(property);
            }
            property.setName(textList.get(0).getText());
            property.setValue(textList.get(1).getText());
        }
        return true;
View Full Code Here

Examples of org.apache.geronimo.jee.connector.AdminobjectInstance

        else if (AdminobjectInstance.class.isInstance(anItem)) {
            Adminobject admin = (Adminobject)tree.getSelection()[0].getParentItem().getData();
            admin.getAdminobjectInstance().remove(anItem);
        }
        else if (ConfigPropertySetting.class.isInstance(anItem)) {
            AdminobjectInstance aoInstance = (AdminobjectInstance)tree.getSelection()[0].getParentItem().getData();
            aoInstance.getConfigPropertySetting().remove(anItem);
        }
    }
View Full Code Here

Examples of org.apache.geronimo.jee.connector.AdminobjectInstance

                if (Adminobject.class.isInstance(parentElement)) {
                    Adminobject admin = (Adminobject)parentElement;
                    return admin.getAdminobjectInstance().toArray();
                }
                if (AdminobjectInstance.class.isInstance(parentElement)) {
                    AdminobjectInstance aoInstance = (AdminobjectInstance)parentElement;
                    return aoInstance.getConfigPropertySetting().toArray();
                }
                return new String[] {};
            }
        };
    }
View Full Code Here

Examples of org.apache.geronimo.jee.connector.AdminobjectInstance

                    Adminobject admin = (Adminobject)element;
                    return "Admin Object: interface = \"" + admin.getAdminobjectInterface() +
                            "\", class = \"" + admin.getAdminobjectClass() + "\"";
                }
                if (AdminobjectInstance.class.isInstance(element)) {
                    AdminobjectInstance aoInstance = (AdminobjectInstance)element;
                    return "Admin Object Instance: message destination name = \"" + aoInstance.getMessageDestinationName() + "\"";
                }
                if (ConfigPropertySetting.class.isInstance(element)) {
                    ConfigPropertySetting property = (ConfigPropertySetting)element;
                    return "Config Property Setting: name = \"" + property.getName() +
                            "\", value = \"" + property.getValue() + "\"";
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.