Package sk.linhard.openair.eventmodel

Examples of sk.linhard.openair.eventmodel.Show


      if (queue.isEmpty()) {
        appended = false;
      } else {
        appended = append(aTime, queue.getFirst());
        if (appended) {
          Show p = queue.removeFirst();
          if (p.isOldVersion()) { // is eliminable ?
            if (result == null) {
              result = new HashSet<Show>();
            }
            result.add(p);
          }
View Full Code Here


      type = StageProgramItemData.CANCELLED;
    } else if (p.isNewVersion()) {
      type = StageProgramItemData.NEW;
    } else if (p.isOldVersion()) {
      type = StageProgramItemData.OLD;
      Show pnew = p.getNewVersion();
      if (pnew.isRelevant(aTime)) { // only display hint when the replacement performance is relevant
        hint = "\u2192 " + DateUtil.format(pnew.getStart(), "HH:mm");
        if (p.isMoved()) { // moved to different stage, append also stage name
          hint += ", " + pnew.getStage().getName();
        }
      }
    }
    // TODO: we want to show short name if available
    return new StageProgramItemData(type, p.getName(),  getFormattedTimes(p), hint);
View Full Code Here

   */
  private DateTime getNextChange(DayProgram dp, DateTime aTime) {
    if (!dp.hasRelevantShows(aTime)) {
      return null;
    }
    Show relp = dp.getRelevantShows(aTime)[0];
    if (relp.isRunning(aTime)) {
      return relp.getEnd();
    }
    return relp.getStart();
  }
View Full Code Here

          for (int k = 0; k < dayKids.getLength(); k++) {
            Node showNode = dayKids.item(k);
            if (showNode.getNodeType() != Node.ELEMENT_NODE && !showNode.getNodeName().equals("show")) {
              continue;
            }
            Show show = dayProgram.addShow(
                showNode.getAttributes().getNamedItem("name").getTextContent(),
                Util.dateTime(showNode.getAttributes().getNamedItem("start").getTextContent()),
                Util.duration(showNode.getAttributes().getNamedItem("duration").getTextContent())
            );
            if (showNode.getAttributes().getNamedItem("shortName") != null) {
              show.setShortName(showNode.getAttributes().getNamedItem("shortName").getTextContent());
            }
            if (showNode.getAttributes().getNamedItem("cancelled") != null) {
              show.setCancelled(new Boolean(showNode.getAttributes().getNamedItem("cancelled").getTextContent()));
            }
            if (showNode.getAttributes().getNamedItem("id") != null) {
              String showId = showNode.getAttributes().getNamedItem("id").getTextContent();
              ShowMetadata showMetadata = (ShowMetadata) metadata.get(showId);
              if (showMetadata != null) {
                show.setMetadata(showMetadata);
              }
              Show theOtherShow = showById.get(showId);
              if (theOtherShow != null) {
                if (showNode.getAttributes().getNamedItem("oldVersion") == null
                  || new Boolean(showNode.getAttributes().getNamedItem("oldVersion").getTextContent())) {
                  show.setNewVersion(theOtherShow);
                  theOtherShow.setOldVersion(show);
                } else {
                  show.setOldVersion(theOtherShow);
                  theOtherShow.setNewVersion(show);
                }
              } else {
                // we don't know our other show yet
                showById.put(showId, show);
              }
View Full Code Here

    stageBday1.addShow("Performance B2", dateTime("01-01-2010 11:30"), duration("1:00"));
    stageBday1.addShow("Performance B3", dateTime("01-01-2010 13:00"), duration("1:00"));

    DayProgram stageBday2 = stageB.addDay(dateTime("02-01-2010 0:00"));
    stageBday2.addShow("Performance B4", dateTime("02-01-2010 10:00"), duration("1:00"));
    Show b5 = stageBday2.addShow("Performance B5", dateTime("02-01-2010 11:30"), duration("1:00"));
    Show b6 = stageBday2.addShow("Performance B6", dateTime("02-01-2010 13:00"), duration("2:00"));
   
    Show b5new = b5.change(null, dateTime("02-01-2010 15:30"), duration("1:00"));
    b6.cancel();
   
    Stage stageC = e.addStage("Stage C");
    DayProgram stageCday1 = stageC.addDay(dateTime("01-01-2010 0:00"));
    stageCday1.addShow("Performance C1", dateTime("01-01-2010 10:00"), duration("1:00"));
View Full Code Here

TOP

Related Classes of sk.linhard.openair.eventmodel.Show

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.