Package org.apache.xmlbeans

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


        this.dataObjectFormatMimeTypes.put(dsReferenceUri, mimetype);
    }

    protected static void insertXChild(XmlObject root, XmlObject child) {
        XmlCursor rootCursor = root.newCursor();
        rootCursor.toEndToken();
        XmlCursor childCursor = child.newCursor();
        childCursor.toNextToken();
        childCursor.moveXml(rootCursor);
        childCursor.dispose();
        rootCursor.dispose();
View Full Code Here


   {
      parent = getRootElement( parent );
      XmlCursor parentCursor = parent.newCursor(  );
      if ( parentCursor.toLastChild(  ) ) // has children
      {
         parentCursor.toEndToken(  );
         parentCursor.toNextToken(  );
      }
      else // childless
      {
         parentCursor.toEndToken(  );
View Full Code Here

         parentCursor.toEndToken(  );
         parentCursor.toNextToken(  );
      }
      else // childless
      {
         parentCursor.toEndToken(  );
      }

      parentCursor.insertElement( name );
      parentCursor.toPrevSibling(  );
      XmlObject newChild = parentCursor.getObject(  );
View Full Code Here

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

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

   
    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

                        try {
                            other.toParent();
                            if (other.toChild(SYSTEM_NAMESPACE, "gbean")) {
                                other.toPrevToken();
                            } else {
                                other.toEndToken();
                                other.toPrevToken();
                            }
                            cursor.moveXml(other);
                            cursor.pop();
                            cursor.push();
View Full Code Here

                switch (token)
                {
                    case TokenType.INT_START:
                        if (seenElement) return true;
                        seenElement = true;
                        token = c.toEndToken().intValue();
                        break SWITCH;

                    case TokenType.INT_TEXT:
                        if (! Splay.isWhiteSpace(c.getChars()))
                            return true;
View Full Code Here

        // _firstToken = ((JavelinAnnotation)cur.getAnnotation(JavelinAnnotation.class)).getStartToken();

        // now peek at the end tag (it may be unplaced for the <a/> case, so use the start tag if needed
        cur.toCursor(cursor);
        // _lastToken = ((JavelinAnnotation)cur.getAnnotation(JavelinAnnotation.class)).getEndToken();
        cur.toEndToken();
        // JavelinAnnotation endAnn = (JavelinAnnotation)cur.getAnnotation(JavelinAnnotation.class);
        // if (endAnn != null)
        //    _lastToken = endAnn.getEndToken();
    }
View Full Code Here

        c.toFirstChild();

        XmlObject base = c.getObject();

        c.toEndToken();
        c.insertElement( "bar" );

        Assert.assertTrue( !x.validate() );

        c.toPrevSibling();
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.