Package org.apache.xmlbeans

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


    public ReferencePatterns getReferences(XmlObject xmlObject, DeploymentContext context, AbstractName parentName, ClassLoader classLoader) throws DeploymentException {
        List<GBeanData> uses = new ArrayList<GBeanData>();
        GerLoginConfigType loginConfig = (GerLoginConfigType) xmlObject.copy().changeType(GerLoginConfigType.type);
        XmlCursor xmlCursor = loginConfig.newCursor();
        xmlCursor.push();
        try {
            //munge xml
            if (xmlCursor.toChild(LOGIN_MODULE_QNAME)) {
                do {
                    xmlCursor.removeAttribute(SERVER_SIDE_QNAME);
View Full Code Here


    public static XmlObject fixGeronimoSchema(XmlObject rawPlan, QName desiredElement, SchemaType desiredType) throws XmlException {
        XmlCursor cursor = rawPlan.newCursor();
        try {
            if (findNestedElement(cursor, desiredElement)) {
                cursor.push();
                convertToGeronimoSubSchemas(cursor);
                cursor.pop();
                XmlObject temp = cursor.getObject();

                XmlObject result = temp.changeType(desiredType);
View Full Code Here

        XmlCursor c = org.apache.xmlbeans.XmlObject.Factory.parse(xml).newCursor();
        c.toFirstContentToken(); // on <root>
        c.toFirstContentToken(); // on <a>
        c.toFirstChild();        // on <b>
        c.toFirstChild();        // on <c>
        c.push(); System.out.println(generateXPath(c, null, ns)); c.pop();
        c.toNextSibling();
        c.toNextSibling();       // on the last <c>
        c.push(); System.out.println(generateXPath(c, null, ns)); c.pop();
        XmlCursor d = c.newCursor();
        d.toParent();
View Full Code Here

        c.toFirstChild();        // on <b>
        c.toFirstChild();        // on <c>
        c.push(); System.out.println(generateXPath(c, null, ns)); c.pop();
        c.toNextSibling();
        c.toNextSibling();       // on the last <c>
        c.push(); System.out.println(generateXPath(c, null, ns)); c.pop();
        XmlCursor d = c.newCursor();
        d.toParent();
        c.push(); System.out.println(generateXPath(c, d, ns)); c.pop();
        d.toParent();
        c.push(); System.out.println(generateXPath(c, d, ns)); c.pop();
View Full Code Here

    public static XmlObject fixGeronimoSchema(XmlObject rawPlan, QName desiredElement, SchemaType desiredType) throws XmlException {
        XmlCursor cursor = rawPlan.newCursor();
        try {
            if (findNestedElement(cursor, desiredElement)) {
                cursor.push();
                convertToGeronimoSubSchemas(cursor);
                cursor.pop();
                XmlObject temp = cursor.getObject();

                XmlObject result = temp.changeType(desiredType);
View Full Code Here

                    moveable.toCursor(cursor);
                    cursor.toFirstChild();
                    cursor.beginElement("outbound-resourceadapter", SchemaConversionUtils.J2EE_NAMESPACE);
                    cursor.beginElement("connection-definition", SchemaConversionUtils.J2EE_NAMESPACE);
                    moveable.toChild(SchemaConversionUtils.J2EE_NAMESPACE, "managedconnectionfactory-class");
                    moveable.push();
                    //from moveable to cursor
                    moveable.moveXml(cursor);
                    while (moveable.toNextSibling(SchemaConversionUtils.J2EE_NAMESPACE, "config-property")) {
                        moveable.moveXml(cursor);
                    }
View Full Code Here

    public ReferencePatterns getReferences(XmlObject xmlObject, DeploymentContext context, AbstractName parentName, ClassLoader classLoader) throws DeploymentException {
        List<GBeanData> uses = new ArrayList<GBeanData>();
        GerLoginConfigType loginConfig = (GerLoginConfigType) xmlObject.copy().changeType(GerLoginConfigType.type);
        XmlCursor xmlCursor = loginConfig.newCursor();
        xmlCursor.push();
        try {
            //munge xml
            if (xmlCursor.toChild(LOGIN_MODULE_QNAME)) {
                do {
                    xmlCursor.removeAttribute(SERVER_SIDE_QNAME);
View Full Code Here

    public static XmlObject fixGeronimoSchema(XmlObject rawPlan, QName desiredElement, SchemaType desiredType) throws XmlException {
        XmlCursor cursor = rawPlan.newCursor();
        try {
            if (findNestedElement(cursor, desiredElement)) {
                cursor.push();
                convertToGeronimoSubSchemas(cursor);
                cursor.pop();
                XmlObject temp = cursor.getObject();

                XmlObject result = temp.changeType(desiredType);
View Full Code Here

    public ReferencePatterns getReferences(XmlObject xmlObject, DeploymentContext context, AbstractName parentName, Bundle bundle) throws DeploymentException {
        List<GBeanData> uses = new ArrayList<GBeanData>();
        GerLoginConfigType loginConfig = (GerLoginConfigType) xmlObject.copy().changeType(GerLoginConfigType.type);
        XmlCursor xmlCursor = loginConfig.newCursor();
        xmlCursor.push();
        try {
            //munge xml
            if (xmlCursor.toChild(LOGIN_MODULE_QNAME)) {
                do {
                    xmlCursor.removeAttribute(SERVER_SIDE_QNAME);
View Full Code Here

    public static XmlObject fixGeronimoSchema(XmlObject rawPlan, QName desiredElement, SchemaType desiredType) throws XmlException {
        XmlCursor cursor = rawPlan.newCursor();
        try {
            if (findNestedElement(cursor, desiredElement)) {
                cursor.push();
                convertToGeronimoSubSchemas(cursor);
                cursor.pop();
                XmlObject temp = cursor.getObject();

                XmlObject result = temp.changeType(desiredType);
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.