Exemple #1
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;
 }
Exemple #2
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;
 }