27 * |
27 * |
28 */ |
28 */ |
29 package de.uapcore.lightpit.dao; |
29 package de.uapcore.lightpit.dao; |
30 |
30 |
31 import java.sql.SQLException; |
31 import java.sql.SQLException; |
32 import java.util.List; |
|
33 |
32 |
34 public interface GenericDao<T> { |
33 public interface GenericDao<T> { |
35 /** |
|
36 * Returns a list of all entities. |
|
37 * |
|
38 * @return a list of all objects |
|
39 * @throws SQLException on any kind of SQL errors |
|
40 */ |
|
41 List<T> list() throws SQLException; |
|
42 |
34 |
43 /** |
35 /** |
44 * Finds an entity by its integer ID. |
36 * Finds an entity by its integer ID. |
45 * |
37 * |
46 * @param id the id |
38 * @param id the id |