|
Jive Forums API (5.5.20.2-oracle) Developer Javadocs | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jivesoftware.forum.webservices.server.WatchServiceImpl
public class WatchServiceImpl
Field Summary |
---|
Fields inherited from interface com.jivesoftware.forum.webservices.WatchService |
---|
OBJECT_FORUM, OBJECT_FORUM_CATEGORY, OBJECT_THREAD, OBJECT_USER |
Constructor Summary | |
---|---|
WatchServiceImpl()
|
Method Summary | |
---|---|
Watch |
createCategoryWatch(long userID,
long categoryID)
Create a watch on a category for the specified user. |
Watch |
createForumWatch(long userID,
long forumID)
Create a watch on a forum for the user with the specified ID. |
Watch |
createThreadWatch(long userID,
long threadID)
Create a watch on a thread for the specified user. |
Watch |
createUserWatch(long userID,
long watchedUserID)
Create a watch on a user for the specified user. |
void |
deleteWatch(Watch watch)
Delete the specified watch. |
void |
deleteWatches(long userID)
Deletes all watches that a user has. |
Watch |
getCategoryWatch(long userID,
long categoryID)
Returns a watch on a particular category, or null if there isn't a watch. |
int |
getCategoryWatchCount(long userID,
long categoryID)
Return the count of all forum watches in a particular categoryID for the given userID. |
long[] |
getCategoryWatches(long userID,
long categoryID)
Returns an array of IDs for all the forum objects a user is watching in a category. |
Forum[] |
getCategoryWatchObjects(long userID,
long categoryID,
int startIndex,
int numResults)
Returns Forums that the user is watching for a given category. |
int |
getDeleteDays()
Returns the number of days that a watched object can remain inactive before watches on that object are deleted. |
ForumThread[] |
getForumThreadWatchesByCategory(long userID,
long categoryID,
int startIndex,
int numResults)
Returns ForumThreads that the user is watching for all the Forums under the given Category. |
Watch |
getForumWatch(long userID,
long forumID)
Returns a watch on a particular forum, or null if there isn't a watch. |
int |
getForumWatchCount(long userID,
long forumID)
Return the count of all thread watches in a particular forumID for the given user. |
long[] |
getForumWatches(long userID,
long forumID)
Returns an array of IDs for the threads a user is watching in a forum. |
ForumThread[] |
getForumWatchObjects(long userID,
long forumID,
int startIndex,
int numResults)
Returns ForumThreads that the user is watching for a given Forum. |
int |
getRecursiveForumThreadWatchCountByCategory(long userID,
long categoryID)
Return the count of all thread watches in a particular categoryID for the given user. |
ForumThread[] |
getRecursiveForumThreadWatchesByCategory(long userID,
long categoryID,
int startIndex,
int numResults)
Returns ForumThreads that the user is watching for all the Forums under the given Category. |
int |
getRecursiveForumWatchCountByCategory(long userID,
long categoryID)
Return the count of all forum watches in a particular categoryID for the given userID. |
Forum[] |
getRecursiveForumWatchesByCategory(long userID,
long categoryID,
int startIndex,
int numResults)
Returns Forums that the user is watching for a given category and all of its subcategories. |
Watch |
getThreadWatch(long userID,
long threadID)
Returns a watch on a particular thread, or null if there isn't a watch. |
int |
getTotalWatchCount(long userID,
int objectType)
Returns a count of all watches that a userID has of a particular type. |
Watch |
getUserWatch(long userID,
long watchedUserID)
Returns a watch on a particular user, or null if there isn't a watch. |
User[] |
getWatchers(int objectType,
long objectID)
Returns the Users who are watching the specified object. |
Watch[] |
getWatchList(long userID,
int objectType)
Returns an array of Watch objects for a particular object type that the given user is watching. |
boolean |
isCategoryWatched(long userID,
long categoryID)
Returns true if the user is watching the specified category. |
boolean |
isForumWatched(long userID,
long forumID)
Returns true if the user is watching the specified forum. |
boolean |
isThreadWatched(long userID,
long threadID)
Returns true if the user is watching the specified thread. |
boolean |
isUserWatched(long userID,
long watchedUserID)
Returns true if the user is watching the specified user. |
void |
setDeleteDays(int deleteDays)
Sets the number of days that a watched object can remain inactive before watches on that object are deleted. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public WatchServiceImpl()
Method Detail |
---|
public int getDeleteDays()
WatchService
getDeleteDays
in interface WatchService
public void setDeleteDays(int deleteDays)
WatchService
setDeleteDays
in interface WatchService
deleteDays
- The number days a watch can be inactive before being
automatically deleted.public Watch createUserWatch(long userID, long watchedUserID) throws UserNotFoundException
WatchService
createUserWatch
in interface WatchService
userID
- The ID of the user to set the watch for.watchedUserID
- The ID of the user to watch.
UserNotFoundException
public Watch createThreadWatch(long userID, long threadID) throws UserNotFoundException, ForumThreadNotFoundException
WatchService
createThreadWatch
in interface WatchService
userID
- The ID of the user to set the watch for.threadID
- The ID of thread to watch.
UserNotFoundException
ForumThreadNotFoundException
public Watch createForumWatch(long userID, long forumID) throws UserNotFoundException, ForumNotFoundException
WatchService
createForumWatch
in interface WatchService
userID
- The ID of the user to set a watch for.forumID
- The ID of the forum to watch.
UserNotFoundException
ForumNotFoundException
public Watch createCategoryWatch(long userID, long categoryID) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
createCategoryWatch
in interface WatchService
userID
- The ID of the user to set the watch for.categoryID
- The ID of the category to watch.
UserNotFoundException
ForumCategoryNotFoundException
public int getForumWatchCount(long userID, long forumID) throws UserNotFoundException, ForumNotFoundException
WatchService
getForumWatchCount
in interface WatchService
userID
- The ID of the user to return the watch count for.forumID
- The ID of the forum to get the watch count for.
UserNotFoundException
ForumNotFoundException
public int getCategoryWatchCount(long userID, long categoryID) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getCategoryWatchCount
in interface WatchService
userID
- The userID to return the watch count for.categoryID
- The categoryID to return the watch count for.
UserNotFoundException
ForumCategoryNotFoundException
public int getTotalWatchCount(long userID, int objectType) throws UserNotFoundException
WatchService
getTotalWatchCount
in interface WatchService
userID
- The ID of the user to get the watch count for.objectType
- The object type to get a watch count for.
UserNotFoundException
public Watch[] getWatchList(long userID, int objectType) throws UserNotFoundException
WatchService
WatchService.OBJECT_THREAD
WatchService.OBJECT_FORUM
WatchService.OBJECT_FORUM_CATEGORY
WatchService.OBJECT_USER
getWatchList
in interface WatchService
userID
- the userID to retrieve watches forobjectType
- the object type.
UserNotFoundException
public long[] getForumWatches(long userID, long forumID) throws UserNotFoundException, ForumNotFoundException
WatchService
getForumWatches
in interface WatchService
userID
- The ID of the user.forumID
- The ID of the forum.
UserNotFoundException
ForumNotFoundException
public long[] getCategoryWatches(long userID, long categoryID) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getCategoryWatches
in interface WatchService
userID
- The ID of the user.categoryID
- The ID of the category.
UserNotFoundException
ForumCategoryNotFoundException
public Watch getUserWatch(long userID, long watchedUserID) throws UserNotFoundException
WatchService
getUserWatch
in interface WatchService
userID
- the userID with the watch.watchedUserID
- the userID being watched.
UserNotFoundException
public Watch getThreadWatch(long userID, long threadID) throws UserNotFoundException, ForumThreadNotFoundException
WatchService
getThreadWatch
in interface WatchService
userID
- The ID of the user with the watch.threadID
- The ID of the thread being watched.
UserNotFoundException
ForumThreadNotFoundException
public Watch getForumWatch(long userID, long forumID) throws UserNotFoundException, ForumNotFoundException
WatchService
getForumWatch
in interface WatchService
userID
- The ID of the user.forumID
- The ID of the forum.
UserNotFoundException
ForumNotFoundException
public Watch getCategoryWatch(long userID, long categoryID) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getCategoryWatch
in interface WatchService
userID
- The ID of the user to acquire a watch for.categoryID
- The ID of the category to acquire the watch for.
UserNotFoundException
ForumCategoryNotFoundException
public boolean isCategoryWatched(long userID, long categoryID) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
isCategoryWatched
in interface WatchService
userID
- The ID of the user.categoryID
- The ID of the category.
UserNotFoundException
ForumCategoryNotFoundException
public boolean isForumWatched(long userID, long forumID) throws UserNotFoundException, ForumNotFoundException
WatchService
isForumWatched
in interface WatchService
userID
- The ID of the user.forumID
- The ID of the forum.
UserNotFoundException
ForumNotFoundException
public boolean isThreadWatched(long userID, long threadID) throws UserNotFoundException, ForumThreadNotFoundException
WatchService
isThreadWatched
in interface WatchService
userID
- The ID of the user.threadID
- The ID of the thread.
UserNotFoundException
ForumThreadNotFoundException
public boolean isUserWatched(long userID, long watchedUserID) throws UserNotFoundException
WatchService
isUserWatched
in interface WatchService
userID
- The ID of the user.watchedUserID
- The ID of the watched user.
UserNotFoundException
public void deleteWatch(Watch watch) throws UserNotFoundException, ForumNotFoundException, ForumCategoryNotFoundException, ForumThreadNotFoundException
WatchService
deleteWatch
in interface WatchService
watch
- The watch to delete.
UserNotFoundException
ForumNotFoundException
ForumCategoryNotFoundException
ForumThreadNotFoundException
public void deleteWatches(long userID) throws UserNotFoundException
WatchService
deleteWatches
in interface WatchService
userID
- The ID of the user.
UserNotFoundException
public User[] getWatchers(int objectType, long objectID)
WatchService
getWatchers
in interface WatchService
objectType
- the object type.objectID
- the object ID
public ForumThread[] getForumWatchObjects(long userID, long forumID, int startIndex, int numResults) throws UserNotFoundException, ForumNotFoundException
WatchService
getForumWatchObjects
in interface WatchService
userID
- The ID of the user.forumID
- The ID of the forum.startIndex
- The offset.numResults
- The max number of results returned.
UserNotFoundException
ForumNotFoundException
public Forum[] getCategoryWatchObjects(long userID, long categoryID, int startIndex, int numResults) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getCategoryWatchObjects
in interface WatchService
userID
- The ID of the user.categoryID
- The ID of the category.startIndex
- The offset.numResults
- The max number of results returned.
UserNotFoundException
ForumCategoryNotFoundException
public ForumThread[] getForumThreadWatchesByCategory(long userID, long categoryID, int startIndex, int numResults) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getForumThreadWatchesByCategory
in interface WatchService
userID
- The ID of the user.categoryID
- The ID of the category.startIndex
- The offset.numResults
- The max number of results returned.
UserNotFoundException
ForumCategoryNotFoundException
public ForumThread[] getRecursiveForumThreadWatchesByCategory(long userID, long categoryID, int startIndex, int numResults) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getRecursiveForumThreadWatchesByCategory
in interface WatchService
userID
- The ID of the user.categoryID
- The ID of the category.startIndex
- The offset.numResults
- The max number of results returned.
UserNotFoundException
ForumCategoryNotFoundException
public Forum[] getRecursiveForumWatchesByCategory(long userID, long categoryID, int startIndex, int numResults) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getRecursiveForumWatchesByCategory
in interface WatchService
userID
- The ID of the user.categoryID
- The ID of the category.startIndex
- The offset.numResults
- The max number of results returned.
UserNotFoundException
ForumCategoryNotFoundException
public int getRecursiveForumThreadWatchCountByCategory(long userID, long categoryID) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getRecursiveForumThreadWatchCountByCategory
in interface WatchService
userID
- The ID of the user to return the watch count for.categoryID
- The ID of the category.
UserNotFoundException
ForumCategoryNotFoundException
public int getRecursiveForumWatchCountByCategory(long userID, long categoryID) throws UserNotFoundException, ForumCategoryNotFoundException
WatchService
getRecursiveForumWatchCountByCategory
in interface WatchService
userID
- The ID of the user to return the watch count for.categoryID
- The ID of the category.
UserNotFoundException
ForumCategoryNotFoundException
|
Jive Forums Project Page | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |