Examples of insertElement()


Examples of org.apache.xmlbeans.XmlCursor.insertElement()

        c = x.newCursor();

        c.toNextToken();

        c.insertElement( "foo" );
        c.insertElement( "bar" );
       
        testTextFrag( x.xmlText(), "<foo/><bar/>" );
    }
   
    public void testLoad ( )
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

        XmlObject x = XmlObject.Factory.newInstance();

        XmlCursor c = x.newCursor();

        c.toNextToken();
        c.insertElement( "foo", "http://p.com" );
        c.toPrevToken();
        c.insertNamespace( "p", "http://p.com" );

        Assert.assertTrue(
            x.xmlText().equals( "<p:foo xmlns:p=\"http://p.com\"/>" ) );
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

        }

        if (getPOSIXApplication(value) == null) {
            XmlCursor acursor = application.newCursor();
            acursor.toEndToken();
            acursor.insertElement(POSIX_APPLICATION);
            acursor.dispose();
        }
        return getPOSIXApplication(value);
    }
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

        ApplicationType application = getOrCreateApplication(value);

        if (getSPMDApplication(value) == null) {
            XmlCursor acursor = application.newCursor();
            acursor.toEndToken();
            acursor.insertElement(SPMD_APPLICATION);
            acursor.dispose();
        }
        return getSPMDApplication(value);
    }
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

        }

        if (getHPCProfileApplication(value) == null) {
            XmlCursor acursor = application.newCursor();
            acursor.toEndToken();
            acursor.insertElement(HPC_PROFILE_APPLICATION);
            acursor.dispose();
        }
        return getHPCProfileApplication(value);
    }
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

            parentCursor.toEndToken();
            parentCursor.toNextToken();
        }
        parentCursor.toEndToken();
        xBean = getRootElement( xBean );
        parentCursor.insertElement( getName( xBean ) );
        parentCursor.toPrevSibling();
        XmlObject childXBean = parentCursor.getObject();
        parentCursor.dispose();
        childXBean.set( xBean );
        return childXBean;
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

        if ( xCursor.toLastChild() )
        {
            xCursor.toEndToken();
        }
        xCursor.toNextToken();
        xCursor.insertElement( name );
        xCursor.toPrevSibling();
        XmlObject childXBean = xCursor.getObject();
        xCursor.dispose();
        return childXBean;       
    }
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

                        SchemaType type = definitionWrapper.findType(typeName);

                        if (type != null) {
                            XmlCursor c = cursor.newCursor();
                            c.toLastChild();
                            c.insertElement(part.getName());
                            c.toPrevToken();

                            xmlGenerator.createSampleForType(type, c);
                            c.dispose();
                        } else
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

                    } else {
                        SchemaGlobalElement element = definitionWrapper.getSchemaTypeLoader().findElement(part.getElementName());
                        if (element != null) {
                            XmlCursor c = cursor.newCursor();
                            c.toLastChild();
                            c.insertElement(element.getName());
                            c.toPrevToken();

                            xmlGenerator.createSampleForType(element.getType(), c);
                            c.dispose();
                        } else
View Full Code Here

Examples of org.apache.xmlbeans.XmlCursor.insertElement()

                        SchemaType type = definitionWrapper.findType(typeName);

                        if (type != null) {
                            XmlCursor c = cursor.newCursor();
                            c.toLastChild();
                            c.insertElement(part.getName());
                            c.toPrevToken();

                            xmlGenerator.createSampleForType(type, c);
                            c.dispose();
                        } else
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.