| java.lang.Object com.Yasna.forum.ForumFactory com.Yasna.forum.database.DbForumFactory
DbForumFactory | public class DbForumFactory extends ForumFactory (Code) | | Database implementation of the ForumFactory interface.
|
Constructor Summary | |
public | DbForumFactory() Creates a new DbForumFactory. |
Method Summary | |
public void | BlackListIP(ClientIP cip, boolean add) | public Iterator | categories() | public void | cleanDatabase() Cleans the Yazd database of "junk". | public Category | createCategory(String name, String description) | public Forum | createForum(String name, String description, boolean moderated, int forumGroupID, boolean article) | public Query | createQuery() | public void | deleteCategory(Category category) | public void | deleteForum(Forum forum) | public Iterator | forums() | public Iterator | forumsModeration() | public Iterator | forumsWithArticlesForums() | public ForumThread | getArticleThread(String pageKey, Forum forum) | public DbCacheManager | getCacheManager() Returns the cache manager object. | public Category | getCategory(int categoryID) | public Category | getCategory(String name) | public Forum | getForum(int forumID) | public Forum | getForum(String name) | public int | getForumCount() | public DbForumGroup | getForumGroup(int forumGroupID, DbCategory category) Returns a forumgroup specified by its id. | protected ForumPermissions | getGroupPermissions(int groupID, int forumID) Returns the permissions that a particular group has for the forum. | protected DbForumMessage | getMessage(int messageID) Returns a message from the thread based on its id. | public ForumPermissions | getPermissions(Authorization authorization) | public ProfileManager | getProfileManager() | public SearchIndexer | getSearchIndexer() | public Iterator | getSessionList() | public SessionManager | getSessionManager() | public DbForumThread | getThread(int threadID, DbForum forum) Returns a thread specified by its id. | public ThreadType | getThreadType(int typeid) | public Iterator | getThreadTypeIterator() | protected ForumPermissions | getUserPermissions(int userID, int forumID) Returns the permissions that a particular user has for the forum. | public EmailWatchManager | getWatchManager() returns the watch manager. | public int | getYesterdayUserCount() | public int[] | groupsWithPermission(int permissionType) | public boolean | hasPermission(int type) | public boolean | isBlackListed(ClientIP cip) | protected void | log(String message, Exception e) Logs events in the system. | public int[] | usersWithPermission(int permissionType) |
DbForumFactory | public DbForumFactory()(Code) | | Creates a new DbForumFactory.
|
cleanDatabase | public void cleanDatabase()(Code) | | Cleans the Yazd database of "junk". This is currently defined as:
- Messages with no subject or body.
- Messages that do not belong to a thread.
Please be aware that this method will permanently delete forum
content. You may want to perform a database backup before calling this
method.
This method requires two database connections and may take a long time
to execute, as it must iterate through ever message record in the
database.
|
forumsWithArticlesForums | public Iterator forumsWithArticlesForums()(Code) | | |
getForumCount | public int getForumCount()(Code) | | |
getGroupPermissions | protected ForumPermissions getGroupPermissions(int groupID, int forumID)(Code) | | Returns the permissions that a particular group has for the forum.
|
getMessage | protected DbForumMessage getMessage(int messageID) throws ForumMessageNotFoundException(Code) | | Returns a message from the thread based on its id. If cache is turned
on, it will use it.
Parameters: messageID - the ID of the message to get from the thread. |
getUserPermissions | protected ForumPermissions getUserPermissions(int userID, int forumID)(Code) | | Returns the permissions that a particular user has for the forum.
|
getWatchManager | public EmailWatchManager getWatchManager()(Code) | | returns the watch manager. This is only used by this package.
watchmanager |
getYesterdayUserCount | public int getYesterdayUserCount()(Code) | | |
hasPermission | public boolean hasPermission(int type)(Code) | | |
log | protected void log(String message, Exception e)(Code) | | Logs events in the system. Very beginnings here....
|
Methods inherited from com.Yasna.forum.ForumFactory | abstract public void BlackListIP(ClientIP cip, boolean add) throws UnauthorizedException(Code)(Java Doc) abstract public Iterator categories()(Code)(Java Doc) abstract public Category createCategory(String name, String description) throws UnauthorizedException, CategoryAlreadyExistsException(Code)(Java Doc) abstract public Forum createForum(String name, String description, boolean moderated, int forumGroupID, boolean article) throws UnauthorizedException, ForumAlreadyExistsException(Code)(Java Doc) abstract public Query createQuery()(Code)(Java Doc) abstract public void deleteCategory(Category category) throws UnauthorizedException(Code)(Java Doc) abstract public void deleteForum(Forum forum) throws UnauthorizedException(Code)(Java Doc) abstract public Iterator forums()(Code)(Java Doc) abstract public Iterator forumsModeration()(Code)(Java Doc) abstract public Iterator forumsWithArticlesForums()(Code)(Java Doc) abstract public ForumThread getArticleThread(String pageKey, Forum forum) throws ForumThreadNotFoundException, UnauthorizedException(Code)(Java Doc) abstract public Category getCategory(int categoryID) throws CategoryNotFoundException, UnauthorizedException(Code)(Java Doc) abstract public Category getCategory(String name) throws CategoryNotFoundException, UnauthorizedException(Code)(Java Doc) abstract public Forum getForum(int forumID) throws ForumNotFoundException, UnauthorizedException(Code)(Java Doc) abstract public Forum getForum(String name) throws ForumNotFoundException, UnauthorizedException(Code)(Java Doc) abstract public int getForumCount()(Code)(Java Doc) public static ForumFactory getInstance(Authorization authorization)(Code)(Java Doc) abstract public ForumPermissions getPermissions(Authorization authorization)(Code)(Java Doc) abstract public ProfileManager getProfileManager()(Code)(Java Doc) abstract public SearchIndexer getSearchIndexer() throws UnauthorizedException(Code)(Java Doc) abstract public Iterator getSessionList()(Code)(Java Doc) abstract public ThreadType getThreadType(int typeid)(Code)(Java Doc) abstract public Iterator getThreadTypeIterator()(Code)(Java Doc) abstract public int getYesterdayUserCount()(Code)(Java Doc) abstract public int[] groupsWithPermission(int permissionType) throws UnauthorizedException(Code)(Java Doc) abstract public boolean hasPermission(int type)(Code)(Java Doc) abstract public boolean isBlackListed(ClientIP cip)(Code)(Java Doc) abstract public int[] usersWithPermission(int permissionType) throws UnauthorizedException(Code)(Java Doc)
|
|
|