Package org.dom4j

Examples of org.dom4j.Document.asXML()


    List<FolderPermissionEntity> list = getDao().getFolderPermissionDao()
        .selectByFolder(folder.getId());
    for (FolderPermissionEntity permission : list) {
      createFolderPermissionXML(p, permission);
    }
    return doc.asXML();
  }

  private void createFolderPermissionXML(Element permissionsElement,
      final FolderPermissionEntity permission) {
    GroupEntity group = getDao().getGroupDao().getById(
View Full Code Here


    Document doc = DocumentHelper.createDocument();
    Element root = doc.addElement("template");
    root.addElement("title").addText(theme.getTitle());
    root.addElement("url").addText(theme.getUrl());
    root.addElement("content").addText(theme.getContent());
    return doc.asXML();
  }
 
  private void addThemeResources(final ZipOutStreamTaskAdapter out,
      final TemplateEntity theme) throws IOException,
      TaskTimeoutException {
View Full Code Here

  @Override
  public String createGroupsXML() {
    Document doc = DocumentHelper.createDocument();
    Element groupsElement = doc.addElement("groups");
    createGroupsXML(groupsElement);
    return doc.asXML();
  }

  private void createGroupsXML(Element groupsElement) {
    List<GroupEntity> list = getDao().getGroupDao().select();
    for (GroupEntity Group : list) {
View Full Code Here

  public String createPageContentXML(PageEntity page) {
    Document doc = DocumentHelper.createDocument();
    Element pageElement = doc.addElement("page");
    createPageDetailsXML(page, pageElement);
    createPageVersionXML(page, pageElement);
    return doc.asXML();
  }
 
  public String createPageCommentsXML(String pageURL) {
    Document doc = DocumentHelper.createDocument();
    Element rootElement = doc.addElement("comments");
View Full Code Here

 
  public String createPageCommentsXML(String pageURL) {
    Document doc = DocumentHelper.createDocument();
    Element rootElement = doc.addElement("comments");
    createCommentsXML(pageURL, rootElement);
    return doc.asXML();
  }

  public String createPagePermissionsXML(String pageURL) {
    Document doc = DocumentHelper.createDocument();
    Element e = doc.addElement("permissions");
View Full Code Here

  public String createPagePermissionsXML(String pageURL) {
    Document doc = DocumentHelper.createDocument();
    Element e = doc.addElement("permissions");
    getPagePermissionExporter().createPagePermissionsXML(e,
        pageURL);
    return doc.asXML();
  }

  public String createPageTagXML(String pageURL) {
    Document doc = DocumentHelper.createDocument();
    Element e = doc.addElement("tags");
View Full Code Here

        Element tagElement = e.addElement("tag");
        tagElement.addElement("name").setText(
            getBusiness().getTagBusiness().getPath(tag));
      }
    }
    return doc.asXML();
  }

  private void createPageVersionXML(PageEntity page, Element pageElement) {
    List<PageEntity> versions = getDao().getPageDao().selectByUrl(
        page.getFriendlyURL());
View Full Code Here

  @Override
  public String createConfigXML() {
    Document doc = DocumentHelper.createDocument();
    Element configElement = doc.addElement("config");
    createConfigXML(configElement);
    return doc.asXML();
  }   
 
  private void createConfigXML(Element configElement) {
    ConfigEntity config = getConfig();
    configElement.addElement("google-analytics").setText(notNull(
View Full Code Here

    for (SeoUrlEntity seo : list) {
      Element seoElement = e.addElement("seo-url");
      seoElement.addElement("from").setText(seo.getFromLink());
      seoElement.addElement("to").setText(seo.getToLink());
    }
    return doc.asXML();
  }

  public void read(Element urlsElement) throws DaoTaskException {
    for (Iterator<Element> i = urlsElement.elementIterator();
        i.hasNext(); ) {
View Full Code Here

  @Override
  public String createStructuresXML() {
    Document doc = DocumentHelper.createDocument();
    Element structuresElement = doc.addElement("structures");
    createStructuresXML(structuresElement);
    return doc.asXML();
  }

  private void createStructuresXML(Element structuresElement) {
    List<StructureEntity> list = getDao().getStructureDao().select();
    for (StructureEntity structure : list) {
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.