Examples of SMInputCursor


Examples of org.codehaus.staxmate.in.SMInputCursor

    if (duplicationsData != null) {
      try {
        SMInputFactory inputFactory = initStax();
        SMHierarchicCursor root = inputFactory.rootElementCursor(new StringReader(duplicationsData));
        root.advance(); // <duplications>
        SMInputCursor cursor = root.childElementCursor("g");
        while (cursor.getNext() != null) {
          List<Duplication> duplications = newArrayList();
          SMInputCursor bCursor = cursor.childElementCursor("b");
          while (bCursor.getNext() != null) {
            String from = bCursor.getAttrValue("s");
            String size = bCursor.getAttrValue("l");
            String componentKey = bCursor.getAttrValue("r");
            if (from != null && size != null && componentKey != null) {
              duplications.add(createDuplication(componentsByKey, from, size, componentKey, session));
            }
          }
          Collections.sort(duplications, new DuplicationComparator(component));
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.