diff -r ed84c8bdd87b -r f8894df2d079 src/org/sonews/storage/Storage.java --- a/src/org/sonews/storage/Storage.java Sun Aug 29 17:28:58 2010 +0200 +++ b/src/org/sonews/storage/Storage.java Wed May 04 18:06:24 2011 +0200 @@ -30,121 +30,120 @@ public interface Storage { - /** - * Stores the given Article in the storage. - * @param art - * @throws StorageBackendException - */ - void addArticle(Article art) - throws StorageBackendException; + /** + * Stores the given Article in the storage. + * @param art + * @throws StorageBackendException + */ + void addArticle(Article art) + throws StorageBackendException; - void addEvent(long timestamp, int type, long groupID) - throws StorageBackendException; + void addEvent(long timestamp, int type, long groupID) + throws StorageBackendException; - void addGroup(String groupname, int flags) - throws StorageBackendException; + void addGroup(String groupname, int flags) + throws StorageBackendException; - int countArticles() - throws StorageBackendException; + int countArticles() + throws StorageBackendException; - int countGroups() - throws StorageBackendException; + int countGroups() + throws StorageBackendException; - void delete(String messageID) - throws StorageBackendException; + void delete(String messageID) + throws StorageBackendException; - Article getArticle(String messageID) - throws StorageBackendException; + Article getArticle(String messageID) + throws StorageBackendException; - Article getArticle(long articleIndex, long groupID) - throws StorageBackendException; + Article getArticle(long articleIndex, long groupID) + throws StorageBackendException; - List> getArticleHeads(Group group, long first, long last) - throws StorageBackendException; + List> getArticleHeads(Group group, long first, long last) + throws StorageBackendException; - List> getArticleHeaders(Channel channel, long start, long end, - String header, String pattern) - throws StorageBackendException; + List> getArticleHeaders(Channel channel, long start, long end, + String header, String pattern) + throws StorageBackendException; - long getArticleIndex(Article art, Group group) - throws StorageBackendException; + long getArticleIndex(Article art, Group group) + throws StorageBackendException; - List getArticleNumbers(long groupID) - throws StorageBackendException; + List getArticleNumbers(long groupID) + throws StorageBackendException; - String getConfigValue(String key) - throws StorageBackendException; + String getConfigValue(String key) + throws StorageBackendException; - int getEventsCount(int eventType, long startTimestamp, long endTimestamp, - Channel channel) - throws StorageBackendException; + int getEventsCount(int eventType, long startTimestamp, long endTimestamp, + Channel channel) + throws StorageBackendException; - double getEventsPerHour(int key, long gid) - throws StorageBackendException; + double getEventsPerHour(int key, long gid) + throws StorageBackendException; - int getFirstArticleNumber(Group group) - throws StorageBackendException; + int getFirstArticleNumber(Group group) + throws StorageBackendException; - Group getGroup(String name) - throws StorageBackendException; + Group getGroup(String name) + throws StorageBackendException; - List getGroups() - throws StorageBackendException; + List getGroups() + throws StorageBackendException; - /** - * Retrieves the collection of groupnames that are associated with the - * given list address. - * @param inetaddress - * @return - * @throws StorageBackendException - */ - List getGroupsForList(String listAddress) - throws StorageBackendException; + /** + * Retrieves the collection of groupnames that are associated with the + * given list address. + * @param inetaddress + * @return + * @throws StorageBackendException + */ + List getGroupsForList(String listAddress) + throws StorageBackendException; - int getLastArticleNumber(Group group) - throws StorageBackendException; + int getLastArticleNumber(Group group) + throws StorageBackendException; - /** - * Returns a list of email addresses that are related to the given - * groupname. In most cases the list may contain only one entry. - * @param groupname - * @return - * @throws StorageBackendException - */ - List getListsForGroup(String groupname) - throws StorageBackendException; + /** + * Returns a list of email addresses that are related to the given + * groupname. In most cases the list may contain only one entry. + * @param groupname + * @return + * @throws StorageBackendException + */ + List getListsForGroup(String groupname) + throws StorageBackendException; - String getOldestArticle() - throws StorageBackendException; + String getOldestArticle() + throws StorageBackendException; - int getPostingsCount(String groupname) - throws StorageBackendException; + int getPostingsCount(String groupname) + throws StorageBackendException; - List getSubscriptions(int type) - throws StorageBackendException; + List getSubscriptions(int type) + throws StorageBackendException; - boolean isArticleExisting(String messageID) - throws StorageBackendException; + boolean isArticleExisting(String messageID) + throws StorageBackendException; - boolean isGroupExisting(String groupname) - throws StorageBackendException; + boolean isGroupExisting(String groupname) + throws StorageBackendException; - void purgeGroup(Group group) - throws StorageBackendException; + void purgeGroup(Group group) + throws StorageBackendException; - void setConfigValue(String key, String value) - throws StorageBackendException; + void setConfigValue(String key, String value) + throws StorageBackendException; - /** - * Updates headers and channel references of the given article. - * @param article - * @return - * @throws StorageBackendException - */ - boolean update(Article article) - throws StorageBackendException; + /** + * Updates headers and channel references of the given article. + * @param article + * @return + * @throws StorageBackendException + */ + boolean update(Article article) + throws StorageBackendException; - boolean update(Group group) - throws StorageBackendException; - + boolean update(Group group) + throws StorageBackendException; }