/**
  * Updates an entry
  *
  * @param id The ID of the Entry to update
  */
 public static void editEntry(long id) throws EntryDoesNotExistException {
   Entry ent = null;
   try {
     ent = WinebookDAO.getEntry(id);
     WinebookDAO.editEntry(ent);
   } catch (DAException e) {
     throw new EntryDoesNotExistException(e);
   }
 }
 /**
  * Adds a photo to an entry
  *
  * @param id The ID of the entry to add the photo to
  * @param p The Photo to add to the entry
  */
 public static void addPhoto(long id, Photo p) {
   Entry ent = null;
   try {
     ent = WinebookDAO.getEntry(id);
     ent.addPhoto(p);
     WinebookDAO.editEntry(ent);
   } catch (DAException e) {
     // TODO
   }
 }
 /**
  * Removes a wine from an entry
  *
  * @param entryid The ID of the entry to remove the wine from
  * @param w The wine to remove from the entry
  */
 public static void removeWine(long entryid, Wine w) {
   Entry ent = null;
   try {
     ent = WinebookDAO.getEntry(entryid);
     ent.removeWine(w);
     WinebookDAO.editEntry(ent);
   } catch (DAException e) {
     // TODO
   }
 }
  /**
   * Returns an entry by ID
   *
   * @param id The ID of the entry
   * @return The entry corresponding to the id
   */
  public static Entry getEntry(long id) throws EntryDoesNotExistException {
    Entry ent = null;
    try {
      ent = WinebookDAO.getEntry(id);
    } catch (DAException e) {
      throw new EntryDoesNotExistException(e);
    }

    return ent;
  }