Examples of changeType()


Examples of org.apache.xmlbeans.XmlObject.changeType()

            JettyWebAppType jettyWebApp;
            if (rawPlan != null) {
                XmlObject webPlan = new GenericToSpecificPlanConverter(GerJettyDocument.type.getDocumentElementName().getNamespaceURI(),
                        JettyWebAppDocument.type.getDocumentElementName().getNamespaceURI(), "jetty").convertToSpecificPlan(rawPlan);
                jettyWebApp = (JettyWebAppType) webPlan.changeType(JettyWebAppType.type);
                XmlBeansUtil.validateDD(jettyWebApp);
            } else {
                jettyWebApp = createDefaultPlan();
            }
            return jettyWebApp;
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

    public void testLoadGeronimoDeploymentDescriptor10() throws Exception {
        File geronimoDD = new File(basedir, "src/test-data/connector_1_0/geronimo-ra.xml");
        assertTrue(geronimoDD.exists());
        XmlObject plan = XmlBeansUtil.parse(geronimoDD.toURL());
        GerConnectorDocument connectorDocument = (GerConnectorDocument) plan.changeType(GerConnectorDocument.type);
        GerConnectorType connector = (GerConnectorType) SchemaConversionUtils.fixGeronimoSchema(connectorDocument, "connector", GerConnectorType.type);
        SchemaConversionUtils.validateDD(connector);
        assertEquals(1, connectorDocument.getConnector().getResourceadapterArray().length);
    }
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

    public void testLoadJ2eeDeploymentDescriptor() throws Exception {
        File j2eeDD = new File(basedir, "src/test-data/connector_1_5/ra.xml");
        assertTrue(j2eeDD.exists());
        XmlObject plan = XmlBeansUtil.parse(j2eeDD.toURL());
        ConnectorDocument connectorDocument = (ConnectorDocument) plan.changeType(ConnectorDocument.type);
        assertNotNull(connectorDocument.getConnector().getResourceadapter());
        SchemaConversionUtils.validateDD(connectorDocument);
    }

    public void testLoadGeronimoDeploymentDescriptor15() throws Exception {
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

    public void testLoadGeronimoDeploymentDescriptor15() throws Exception {
        File geronimoDD = new File(basedir, "src/test-data/connector_1_5/geronimo-ra.xml");
        assertTrue(geronimoDD.exists());
        XmlObject plan = XmlBeansUtil.parse(geronimoDD.toURL());
        GerConnectorDocument connectorDocument = (GerConnectorDocument) plan.changeType(GerConnectorDocument.type);
        GerConnectorType connector = (GerConnectorType) SchemaConversionUtils.fixGeronimoSchema(connectorDocument, "connector", GerConnectorType.type);
        assertEquals(1, connector.getResourceadapterArray().length);
    }

    public void testResourceAdapterNameUniqueness() throws Exception {
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

    public void testResourceAdapterNameUniqueness() throws Exception {
        File resourcePlan = new File(basedir, "src/test-data/data/dup-resourceadapter-name.xml");
        assertTrue(resourcePlan.exists());

        XmlObject plan = XmlBeansUtil.parse(resourcePlan.toURL());
        GerConnectorDocument doc = (GerConnectorDocument) plan.changeType(GerConnectorDocument.type);
        if (doc == null) {
            doc = (GerConnectorDocument) plan;
        }
        try {
            SchemaConversionUtils.validateDD(doc);
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

    public void testConnectionFactoryNameUniqueness() throws Exception {
        File resourcePlan = new File(basedir, "src/test-data/data/dup-connectionfactoryinstance-name.xml");
        assertTrue(resourcePlan.exists());

        XmlObject plan = XmlBeansUtil.parse(resourcePlan.toURL());
        GerConnectorDocument doc = (GerConnectorDocument) plan.changeType(GerConnectorDocument.type);
        if (doc == null) {
            doc = (GerConnectorDocument) plan;
        }
        try {
            SchemaConversionUtils.validateDD(doc);
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

    public void testAdminObjectNameUniqueness() throws Exception {
        File resourcePlan = new File(basedir, "src/test-data/data/dup-admin-object-name.xml");
        assertTrue(resourcePlan.exists());

        XmlObject plan = XmlBeansUtil.parse(resourcePlan.toURL());
        GerConnectorDocument doc = (GerConnectorDocument) plan.changeType(GerConnectorDocument.type);
        if (doc == null) {
            doc = (GerConnectorDocument) plan;
        }
        try {
            SchemaConversionUtils.validateDD(doc);
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

    public void testRectifyPlan() throws Exception {
        File resourcePlan = new File(basedir, "src/test-data/data/old-schema-plan.xml");
        assertTrue(resourcePlan.exists());

        XmlObject plan = XmlBeansUtil.parse(resourcePlan.toURL());
        GerConnectorDocument doc = (GerConnectorDocument) plan.changeType(GerConnectorDocument.type);
        if (doc == null) {
            doc = (GerConnectorDocument) plan;
        }
        GerConnectorType gerConnector = doc.getConnector();
        ConnectorPlanRectifier.rectifyPlan(gerConnector);
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

            JettyWebAppType jettyWebApp;
            if (rawPlan != null) {
                XmlObject webPlan = new GenericToSpecificPlanConverter(GerJettyDocument.type.getDocumentElementName().getNamespaceURI(),
                        JettyWebAppDocument.type.getDocumentElementName().getNamespaceURI(), "jetty").convertToSpecificPlan(rawPlan);
                jettyWebApp = (JettyWebAppType) webPlan.changeType(JettyWebAppType.type);
                XmlBeansUtil.validateDD(jettyWebApp);
            } else {
                String defaultContextRoot = determineDefaultContextRoot(webApp, standAlone, moduleFile, targetPath);
                jettyWebApp = createDefaultPlan(defaultContextRoot);
            }
View Full Code Here

Examples of org.apache.xmlbeans.XmlObject.changeType()

            TomcatWebAppType tomcatWebApp = null;
            if (rawPlan != null) {
                XmlObject webPlan = new GenericToSpecificPlanConverter(GerTomcatDocument.type.getDocumentElementName().getNamespaceURI(),
                        TomcatWebAppDocument.type.getDocumentElementName().getNamespaceURI(), "tomcat").convertToSpecificPlan(rawPlan);
                tomcatWebApp = (TomcatWebAppType) webPlan.changeType(TomcatWebAppType.type);
                SchemaConversionUtils.validateDD(tomcatWebApp);
            } else {
                String defaultContextRoot = determineDefaultContextRoot(webApp, standAlone, moduleFile, targetPath);
                tomcatWebApp = createDefaultPlan(defaultContextRoot);
            }
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.