1.1 --- a/src/main/java/de/uapcore/lightpit/dao/IssueDao.java Fri May 22 17:26:27 2020 +0200 1.2 +++ b/src/main/java/de/uapcore/lightpit/dao/IssueDao.java Fri May 22 21:23:57 2020 +0200 1.3 @@ -38,10 +38,31 @@ 1.4 1.5 /** 1.6 * Lists all issues for the specified project. 1.7 + * This is not guaranteed to contain version information. 1.8 + * Use {@link #joinVersionInformation(Issue)} to obtain this information for a specific issue. 1.9 * 1.10 * @param project the project 1.11 * @return a list of issues 1.12 * @throws SQLException on any kind of SQL error 1.13 */ 1.14 List<Issue> list(Project project) throws SQLException; 1.15 + 1.16 + /** 1.17 + * Saves an instances to the database. 1.18 + * Implementations of this DAO must guarantee that the generated ID is stored in the instance. 1.19 + * 1.20 + * @param instance the instance to insert 1.21 + * @throws SQLException on any kind of SQL error 1.22 + * @see Issue#setId(int) 1.23 + */ 1.24 + @Override 1.25 + void save(Issue instance) throws SQLException; 1.26 + 1.27 + /** 1.28 + * Retrieves the affected, scheduled and resolved versions for the specified issue. 1.29 + * 1.30 + * @param issue the issue to join the information for 1.31 + * @throws SQLException on any kind of SQL error 1.32 + */ 1.33 + void joinVersionInformation(Issue issue) throws SQLException; 1.34 }