Package org.eclipse.jst.pagedesigner.dom

Examples of org.eclipse.jst.pagedesigner.dom.DOMRefPosition2


            int startRegionEnd = node.getStartStructuredDocumentRegion()
                .getEnd();
            if (offset <= startRegionEnd) {
              // it is in the start tag region. So put position at first
              // child position.
              return new DOMRefPosition2(node, false);
            }
            return new DOMRefPosition2(node, true);
    } else {
      return new DOMRefPosition(node, true);
    }
    // XXX: the implementation in EditModelQuery seemed to be very complex.
    // Need revisit that
View Full Code Here


    IndexedRegion region1 = model.getIndexedRegion(offset);
    IndexedRegion region2 = model.getIndexedRegion(offset + length);
    IDOMNode node1 = (IDOMNode) region1;

    if (node1 == null) {
      IDOMPosition endOfDoc = new DOMRefPosition2(model.getDocument(),
          true);
      DesignPosition p = DOMPositionHelper.toDesignPosition(endOfDoc);
      return new DesignRange(p, p);
    }
View Full Code Here

        }
        node.appendChild(ele);

        if (node == originalContainer) {
          if (nextSibling == null) {
            return new DOMRefPosition2(ele, true);
          } else if (nextSibling.getParentNode() == ele) {
            // next sibling is not in header part
            return new DOMRefPosition(nextSibling, false);
          } else {
            return new DOMPosition(ele, 0);
View Full Code Here

TOP

Related Classes of org.eclipse.jst.pagedesigner.dom.DOMRefPosition2

Copyright © 2018 www.massapicom. 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.