src/main/java/de/uapcore/lightpit/dao/IssueDao.java

changeset 124
ed2e7aef2a3e
parent 105
250c5cbb8276
child 128
947d0f6a6a83
--- a/src/main/java/de/uapcore/lightpit/dao/IssueDao.java	Fri Oct 09 19:06:51 2020 +0200
+++ b/src/main/java/de/uapcore/lightpit/dao/IssueDao.java	Fri Oct 09 19:07:05 2020 +0200
@@ -29,6 +29,7 @@
 package de.uapcore.lightpit.dao;
 
 import de.uapcore.lightpit.entities.Issue;
+import de.uapcore.lightpit.entities.IssueComment;
 import de.uapcore.lightpit.entities.Project;
 import de.uapcore.lightpit.entities.Version;
 
@@ -59,6 +60,24 @@
     List<Issue> list(Version version) throws SQLException;
 
     /**
+     * Lists all comments for a specific issue in chronological order.
+     *
+     * @param issue the issue
+     * @return the list of comments
+     * @throws SQLException on any kind of SQL error
+     */
+    List<IssueComment> listComments(Issue issue) throws SQLException;
+
+    /**
+     * Stores the specified comment in database.
+     * This is an update-or-insert operation.
+     *
+     * @param comment the comment to save
+     * @throws SQLException on any kind of SQL error
+     */
+    void saveComment(IssueComment comment) throws SQLException;
+
+    /**
      * Saves an instances to the database.
      * Implementations of this DAO must guarantee that the generated ID is stored in the instance.
      *

mercurial