Last change
on this file since 9919 was
9919,
checked in by mlg, 13 years ago
|
Complete rewriting of the api
The api now uses interfaces everywhere (for the dao, services and session manager). This allows the developer to use his own implementations if he wants.
Deletion of the singletons. There are now getters and setters. It allows to make dependency injection.
Use of sl4j in the api, instead of using log4j.
|
File size:
1013 bytes
|
Line | |
---|
1 | package fr.mael.jiwigo.dao; |
---|
2 | |
---|
3 | import java.io.IOException; |
---|
4 | import java.util.List; |
---|
5 | |
---|
6 | import fr.mael.jiwigo.om.Image; |
---|
7 | import fr.mael.jiwigo.om.Tag; |
---|
8 | import fr.mael.jiwigo.transverse.exception.ProxyAuthenticationException; |
---|
9 | |
---|
10 | public interface TagDao { |
---|
11 | /** |
---|
12 | * lists the tags |
---|
13 | * @return the list of tags |
---|
14 | * @throws IOException |
---|
15 | * @throws ProxyAuthenticationException |
---|
16 | */ |
---|
17 | public List<Tag> list() throws IOException, ProxyAuthenticationException; |
---|
18 | |
---|
19 | /** |
---|
20 | * Creation of a tag |
---|
21 | * @param tag the tag to create |
---|
22 | * @return true if the tag as been successfully created |
---|
23 | * @throws ProxyAuthenticationException |
---|
24 | */ |
---|
25 | public boolean create(Tag tag) throws ProxyAuthenticationException; |
---|
26 | |
---|
27 | /** |
---|
28 | * Function that returns the tags for an image |
---|
29 | * @param image the image |
---|
30 | * @return the tags list |
---|
31 | * @throws IOException |
---|
32 | * @throws ProxyAuthenticationException |
---|
33 | */ |
---|
34 | public List<Tag> tagsForImage(Image image) throws IOException, ProxyAuthenticationException; |
---|
35 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.