Package org.dom4j

Examples of org.dom4j.Element.attribute()


        //log.info("createListObjectLibraryByFileDocumentThumbs"+thumbElement);
        LibraryPresentationThumb singleThumb = new LibraryPresentationThumb();
        singleThumb.setName(thumbElement.getName());
        singleThumb.setFilename(thumbElement.getText());
        singleThumb.setLastmod(thumbElement.attribute("lastmod").getText());
        singleThumb.setSize(Long.valueOf(thumbElement.attribute("size").getText()).longValue());
        thumbMap.getThumbs()[k] = singleThumb;
        k++;
      }
     
     
View Full Code Here


     
      for ( Iterator i = pointElements.elementIterator( "point" ); i.hasNext(); ) {
        Element pointElement = (Element) i.next();
        LinkedHashMap<Integer,Object> singlePoint = new LinkedHashMap<Integer,Object>();
        singlePoint.put(0, pointElement.getName());
        singlePoint.put(1, Integer.valueOf(pointElement.attribute("val1").getText()).intValue());
        singlePoint.put(2, Integer.valueOf(pointElement.attribute("val2").getText()).intValue());
        singlePoint.put(3, Integer.valueOf(pointElement.attribute("val3").getText()).intValue());
        singlePoint.put(4, Integer.valueOf(pointElement.attribute("val4").getText()).intValue());
        pointMap.put(k, singlePoint);
        log.debug("createListObjectPaintByNode"+singlePoint);
View Full Code Here

      for ( Iterator i = pointElements.elementIterator( "point" ); i.hasNext(); ) {
        Element pointElement = (Element) i.next();
        LinkedHashMap<Integer,Object> singlePoint = new LinkedHashMap<Integer,Object>();
        singlePoint.put(0, pointElement.getName());
        singlePoint.put(1, Integer.valueOf(pointElement.attribute("val1").getText()).intValue());
        singlePoint.put(2, Integer.valueOf(pointElement.attribute("val2").getText()).intValue());
        singlePoint.put(3, Integer.valueOf(pointElement.attribute("val3").getText()).intValue());
        singlePoint.put(4, Integer.valueOf(pointElement.attribute("val4").getText()).intValue());
        pointMap.put(k, singlePoint);
        log.debug("createListObjectPaintByNode"+singlePoint);
        k++;
View Full Code Here

        Element pointElement = (Element) i.next();
        LinkedHashMap<Integer,Object> singlePoint = new LinkedHashMap<Integer,Object>();
        singlePoint.put(0, pointElement.getName());
        singlePoint.put(1, Integer.valueOf(pointElement.attribute("val1").getText()).intValue());
        singlePoint.put(2, Integer.valueOf(pointElement.attribute("val2").getText()).intValue());
        singlePoint.put(3, Integer.valueOf(pointElement.attribute("val3").getText()).intValue());
        singlePoint.put(4, Integer.valueOf(pointElement.attribute("val4").getText()).intValue());
        pointMap.put(k, singlePoint);
        log.debug("createListObjectPaintByNode"+singlePoint);
        k++;
      }
View Full Code Here

        LinkedHashMap<Integer,Object> singlePoint = new LinkedHashMap<Integer,Object>();
        singlePoint.put(0, pointElement.getName());
        singlePoint.put(1, Integer.valueOf(pointElement.attribute("val1").getText()).intValue());
        singlePoint.put(2, Integer.valueOf(pointElement.attribute("val2").getText()).intValue());
        singlePoint.put(3, Integer.valueOf(pointElement.attribute("val3").getText()).intValue());
        singlePoint.put(4, Integer.valueOf(pointElement.attribute("val4").getText()).intValue());
        pointMap.put(k, singlePoint);
        log.debug("createListObjectPaintByNode"+singlePoint);
        k++;
      }
      subMap.put(1, pointMap);
View Full Code Here

        Element thumbElement = i.next();
        log.info("createListObjectLibraryByFileDocumentThumbs"+thumbElement);
        FilesObject singleThumb = new FilesObject();
        singleThumb.setFileName(thumbElement.getName());
        singleThumb.setFileNamePure(thumbElement.getText());
        singleThumb.setLastModified(thumbElement.attribute("lastmod").getText());
        singleThumb.setFileBytes(thumbElement.attribute("size").getText());
        thumbMap.add(singleThumb);
      }
     
      return thumbMap;
View Full Code Here

        log.info("createListObjectLibraryByFileDocumentThumbs"+thumbElement);
        FilesObject singleThumb = new FilesObject();
        singleThumb.setFileName(thumbElement.getName());
        singleThumb.setFileNamePure(thumbElement.getText());
        singleThumb.setLastModified(thumbElement.attribute("lastmod").getText());
        singleThumb.setFileBytes(thumbElement.attribute("size").getText());
        thumbMap.add(singleThumb);
      }
     
      return thumbMap;
     
View Full Code Here

    for (Iterator<Element> it = root.elementIterator("lang"); it.hasNext();) {

      Element item = it.next();
      String country = item.getText();
      Integer id = Integer.valueOf(item.attribute("id").getValue()).intValue();
     
      String rtl = item.attribute("rightToLeft").getValue();
     
      LinkedHashMap<String,Object> lang = new LinkedHashMap<String,Object>();
      lang.put("id", id);
View Full Code Here

      Element item = it.next();
      String country = item.getText();
      Integer id = Integer.valueOf(item.attribute("id").getValue()).intValue();
     
      String rtl = item.attribute("rightToLeft").getValue();
     
      LinkedHashMap<String,Object> lang = new LinkedHashMap<String,Object>();
      lang.put("id", id);
      lang.put("name", country);
      lang.put("rtl", rtl);
View Full Code Here

    if (root == null) {
      // file was empty;
      return new ArrayList<TextMarker>();
    }
    // Do version check. Not needed now, for future lazy migration code...
    Attribute versionAttribute = root.attribute(XML_VERSION_ATTRIBUTE);
    int version = (versionAttribute == null ? 1 : Integer.parseInt(versionAttribute.getStringValue()));
    if (version != VERSION) {
      // complain about version conflict or solve it
      throw new OLATRuntimeException("Could not load glossary entries due to version conflict. Loaded version was::" + version, null);
    }
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.