示例#1
0
 public List<Release> getPlannedReleases() {
   List<Release> ret = new ArrayList<Release>();
   for (Release release : getReleases()) {
     if (!release.isReleased()) ret.add(release);
   }
   return ret;
 }
示例#2
0
 public BlogEntry createNewBlogEntry(Release release) {
   BlogEntry blogEntry = new BlogEntry(this);
   blogEntry.setTitle("Release " + release.getLabel());
   String text =
       release.isReleased() ? release.getReleaseNotes() : release.createIzemizedReleaseNotes();
   blogEntry.setText(text);
   getDao().createBlogEntry(blogEntry);
   return blogEntry;
 }
示例#3
0
 public Release createNewRelease(Release parentRelease) {
   Release release = new Release(this);
   Date date = Date.today();
   if (parentRelease != null) {
     release.setParentRelease(parentRelease);
     release.setLabel(
         parentRelease.getLabel() + " Bugfix " + (parentRelease.getBugfixReleases().size() + 1));
     Date parentDate = parentRelease.getReleaseDate();
     if (parentDate != null && parentDate.isAfter(date)) date = parentDate;
   }
   release.setReleaseDate(date);
   getDao().createRelease(release);
   return release;
 }