Package net.sf.chellow.monad

Examples of net.sf.chellow.monad.XmlTree


  }

  public void httpGet(Invocation inv) throws HttpException {
    Document doc = MonadUtils.newSourceDocument();
    Element source = doc.getDocumentElement();
    source.appendChild(toXml(doc, new XmlTree("measurementRequirements",
        new XmlTree("tpr"))));
    inv.sendOk(doc);
  }
View Full Code Here


  public void httpGet(Invocation inv) throws DesignerException,
      InternalException, HttpException, DeployerException {
    Document doc = MonadUtils.newSourceDocument();
    Element source = doc.getDocumentElement();

    source.appendChild(toXml(doc, new XmlTree("dno")));
    inv.sendOk(doc);
  }
View Full Code Here

  @SuppressWarnings("unchecked")
  private Document document() throws HttpException {
    Document doc = MonadUtils.newSourceDocument();
    Element source = doc.getDocumentElement();
    source.appendChild(toXml(doc, new XmlTree("bill", new XmlTree("batch",
        new XmlTree("contract"))).put("tpr")));
    source.appendChild(MonadDate.getMonthsXml(doc));
    source.appendChild(MonadDate.getDaysXml(doc));
    source.appendChild(MonadDate.getHoursXml(doc));
    source.appendChild(HhStartDate.getHhMinutesXml(doc));
    for (ReadType type : (List<ReadType>) Hiber.session()
View Full Code Here

    for (SupplyGeneration generation : (List<SupplyGeneration>) Hiber
        .session()
        .createQuery(
            "select supplyGeneration from SupplyGeneration supplyGeneration join supplyGeneration.siteSupplyGenerations siteSupplyGeneration where siteSupplyGeneration.site = :site order by supplyGeneration.finishDate.date")
        .setEntity("site", this).list()) {
      siteElement.appendChild(generation.toXml(doc, new XmlTree("mpans",
          new XmlTree("core").put("llfc")).put("supply", new XmlTree(
          "source"))));
    }
    for (Source source : (List<Source>) Hiber.session()
        .createQuery("from Source source order by source.code").list()) {
      docElem.appendChild(source.toXml(doc));
View Full Code Here

  }

  private Document document() throws HttpException {
    Document doc = MonadUtils.newSourceDocument();
    Element source = doc.getDocumentElement();
    source.appendChild(toXml(doc, new XmlTree("supplyGeneration",
        new XmlTree("supply"))));
    return doc;
  }
View Full Code Here

    Document doc = MonadUtils.newSourceDocument();
    Element source = doc.getDocumentElement();
    Element snagsElement = toXml(doc);
    source.appendChild(snagsElement);
    snagsElement
        .appendChild(channel.toXml(doc, new XmlTree("supplyGeneration",
            new XmlTree("supply").put("hhdcContract"))));
    for (ChannelSnag snag : (List<ChannelSnag>) Hiber
        .session()
        .createQuery(
            "from ChannelSnag snag where snag.channel = :channel order by snag.description, snag.startDate.date")
        .setEntity("channel", channel).setMaxResults(PAGE_SIZE).list()) {
View Full Code Here

    Element source = doc.getDocumentElement();
    Element usersElement = toXml(doc);
    source.appendChild(usersElement);
    for (User user : (List<User>) Hiber.session().createQuery(
        "from User user").list()) {
      usersElement.appendChild(user.toXml(doc, new XmlTree("role").put("party")));
    }
    for (Party party : (List<Party>) Hiber
        .session()
        .createQuery(
            "from Party party order by party.role.code, party.participant.code")
        .list()) {
      source.appendChild(party.toXml(doc, new XmlTree("participant")
          .put("role")));
    }
    return doc;
  }
View Full Code Here

  }

  private Document document() throws HttpException {
    Document doc = MonadUtils.newSourceDocument();
    Element source = doc.getDocumentElement();
    source.appendChild(toXml(doc, new XmlTree("contract", new XmlTree(
        "party"))));
    return doc;
  }
View Full Code Here

    Element source = doc.getDocumentElement();
    Element sscsElement = doc.createElement("sscs");
    source.appendChild(sscsElement);
    for (Ssc ssc : (List<Ssc>) Hiber.session().createQuery(
        "from Ssc ssc order by ssc.code").list()) {
      sscsElement.appendChild(ssc.toXml(doc, new XmlTree(
          "measurementRequirements", new XmlTree("tpr"))));
    }
    inv.sendOk(doc);
  }
View Full Code Here

  private Document document() throws HttpException {
    Document doc = MonadUtils.newSourceDocument();
    Element source = doc.getDocumentElement();
    Element channelsElement = toXml(doc);
    source.appendChild(channelsElement);
    channelsElement.appendChild(generation.toXml(doc, new XmlTree("supply")));
    for (Channel channel : generation.getChannels()) {
      channelsElement.appendChild(channel.toXml(doc));
    }
    return doc;
  }
View Full Code Here

TOP

Related Classes of net.sf.chellow.monad.XmlTree

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.