Jive Forums API (5.5.20.2-oracle) Developer Javadocs

com.jivesoftware.forum.webservices.server
Class ForumThreadServiceImpl

java.lang.Object
  extended by com.jivesoftware.forum.webservices.server.ForumThreadServiceImpl
All Implemented Interfaces:
ForumThreadService

public class ForumThreadServiceImpl
extends java.lang.Object
implements ForumThreadService


Constructor Summary
ForumThreadServiceImpl()
           
 
Method Summary
 void deleteProperty(java.lang.String name, long threadID)
          Delete a property with the given name from the thread with the given ID.
 void deleteThread(long threadID)
          Deletes a thread with the specified ID.
 ForumThread getForumThread(long threadID)
          Returns a ForumThread by its ID.
 ForumThread[] getPopularThreads()
          Returns an array of thread IDs for all the popular threads in the system.
 ForumThread[] getPopularThreadsByCategoryID(long categoryID)
          Returns an array of popular threads by category.
 ForumThread[] getPopularThreadsByForumID(long forumID)
          Returns an array of threadIDs for all the popular threads for a specific forum.
 Property[] getProperties(long threadID)
          Returns all tbe extended properties for the thread with the specified ID.
 java.lang.String getProperty(java.lang.String name, long threadID)
          Returns the value of an extended property for the thread with the specified ID.
 int getThreadCountByCategoryID(long categoryID)
          Returns the number of threads in the specified category.
 int getThreadCountByCategoryIDAndFilter(long CategoryID, ResultFilter filter)
          Returns the number of threads in the specified category after being filtered by the specified filter.
 int getThreadCountByForumID(long forumID)
          Returns a count of all threads under the forum.
 int getThreadCountByForumIDAndFilter(long forumID, ResultFilter filter)
          Returns a count of all threads under the forum filtered by the specified result filter.
 ForumThread[] getThreadsByCategoryID(long categoryID)
          Returns all of the IDs for threads a category.
 ForumThread[] getThreadsByCategoryIDAndFilter(long categoryID, ResultFilter filter)
          Returns all of the IDs for threads a category has filtered by the specified result filter.
 ForumThread[] getThreadsByForumID(long forumID)
          Returns all of the IDs for threads a forum has.
 ForumThread[] getThreadsByForumIDAndFilter(long forumID, ResultFilter filter)
          Returns all of the IDs for threads a forum has filtered by the specified result filter.
 ForumThread[] getThreadsByForumIDAndFilter(long forumID, ResultFilter filter, boolean reduceData)
          Returns all threads in a forum filtered by the specified result filter, with option to set forum name, unfilteredSubject, and unfilteredBody to null to reduce response size.
 void moveThread(long threadID, long forumID)
          Moves the thread with the specified ID to the forum with the specified ID.
 void setProperty(java.lang.String name, java.lang.String value, long threadID)
          Set an extended for the property for the thread with the given ID.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ForumThreadServiceImpl

public ForumThreadServiceImpl()
Method Detail

getForumThread

public ForumThread getForumThread(long threadID)
                           throws ForumThreadNotFoundException
Description copied from interface: ForumThreadService
Returns a ForumThread by its ID.

Specified by:
getForumThread in interface ForumThreadService
Parameters:
threadID - The ID of the thread.
Returns:
The ForumThread object by the ID.
Throws:
ForumThreadNotFoundException

getPopularThreads

public ForumThread[] getPopularThreads()
Description copied from interface: ForumThreadService
Returns an array of thread IDs for all the popular threads in the system.

Specified by:
getPopularThreads in interface ForumThreadService
Returns:
An array of popular thread IDs in the system.

getPopularThreadsByForumID

public ForumThread[] getPopularThreadsByForumID(long forumID)
                                         throws ForumNotFoundException
Description copied from interface: ForumThreadService
Returns an array of threadIDs for all the popular threads for a specific forum.

Specified by:
getPopularThreadsByForumID in interface ForumThreadService
Parameters:
forumID - The ID of the forum to find the popular threads for.
Returns:
An array of IDs for all the popular threads for a specific forum.
Throws:
ForumNotFoundException

getPopularThreadsByCategoryID

public ForumThread[] getPopularThreadsByCategoryID(long categoryID)
                                            throws ForumCategoryNotFoundException
Description copied from interface: ForumThreadService
Returns an array of popular threads by category.

Specified by:
getPopularThreadsByCategoryID in interface ForumThreadService
Parameters:
categoryID - The id of the category.
Returns:
An array of threads for a category.
Throws:
ForumCategoryNotFoundException - Thrown if the specified category does not exist.

getThreadsByForumID

public ForumThread[] getThreadsByForumID(long forumID)
                                  throws ForumNotFoundException
Description copied from interface: ForumThreadService
Returns all of the IDs for threads a forum has. If the number of threads exceeds WSConstants.MAX_THREAD_RESULTS the threads up to WSConstants.MAX_THREAD_RESULTS will be returned.

Specified by:
getThreadsByForumID in interface ForumThreadService
Parameters:
forumID - The ID of the forum to grab threads for.
Returns:
An array of thread IDs for a forum.
Throws:
ForumNotFoundException

getThreadsByForumIDAndFilter

public ForumThread[] getThreadsByForumIDAndFilter(long forumID,
                                                  ResultFilter filter)
                                           throws ForumNotFoundException
Description copied from interface: ForumThreadService
Returns all of the IDs for threads a forum has filtered by the specified result filter.

Specified by:
getThreadsByForumIDAndFilter in interface ForumThreadService
Parameters:
forumID - The forum to grab threads for.
filter - The result filter to filter the results with.
Returns:
An array of thread IDs for a forum.
Throws:
ForumNotFoundException

getThreadsByForumIDAndFilter

public ForumThread[] getThreadsByForumIDAndFilter(long forumID,
                                                  ResultFilter filter,
                                                  boolean reduceData)
                                           throws ForumNotFoundException
Description copied from interface: ForumThreadService
Returns all threads in a forum filtered by the specified result filter, with option to set forum name, unfilteredSubject, and unfilteredBody to null to reduce response size.

Specified by:
getThreadsByForumIDAndFilter in interface ForumThreadService
Parameters:
forumID - The forum to grab threads for.
filter - The result filter to filter the results with.
reduceData - Whether or not to set forum name, unfiltered subject and unfiltered body to null.
Returns:
An array of thread IDs for a forum.
Throws:
ForumNotFoundException

getThreadCountByForumID

public int getThreadCountByForumID(long forumID)
                            throws ForumNotFoundException
Description copied from interface: ForumThreadService
Returns a count of all threads under the forum.

Specified by:
getThreadCountByForumID in interface ForumThreadService
Parameters:
forumID - ID of the forum to find the thread count for
Returns:
a count of all threads under the forum.
Throws:
ForumNotFoundException

getThreadCountByForumIDAndFilter

public int getThreadCountByForumIDAndFilter(long forumID,
                                            ResultFilter filter)
                                     throws ForumNotFoundException
Description copied from interface: ForumThreadService
Returns a count of all threads under the forum filtered by the specified result filter.

Specified by:
getThreadCountByForumIDAndFilter in interface ForumThreadService
Parameters:
forumID - The ID of the forum to find the thread count for.
filter - The result filter to filter results with.
Returns:
A count of all threads under the forum.
Throws:
ForumNotFoundException

getThreadsByCategoryID

public ForumThread[] getThreadsByCategoryID(long categoryID)
                                     throws ForumCategoryNotFoundException
Description copied from interface: ForumThreadService
Returns all of the IDs for threads a category. If the number of threads exceeds WSConstants.MAX_THREAD_RESULTS the threads up to WSConstants.MAX_THREAD_RESULTS will be returned.

Specified by:
getThreadsByCategoryID in interface ForumThreadService
Parameters:
categoryID - The ID of the category to grab threds for.
Returns:
An array of thread IDs for a category.
Throws:
ForumCategoryNotFoundException

getThreadsByCategoryIDAndFilter

public ForumThread[] getThreadsByCategoryIDAndFilter(long categoryID,
                                                     ResultFilter filter)
                                              throws ForumCategoryNotFoundException
Description copied from interface: ForumThreadService
Returns all of the IDs for threads a category has filtered by the specified result filter.

Specified by:
getThreadsByCategoryIDAndFilter in interface ForumThreadService
Parameters:
categoryID - The ID of the category to grab threds for.
Returns:
An array of threads for a category.
Throws:
ForumCategoryNotFoundException

getThreadCountByCategoryID

public int getThreadCountByCategoryID(long categoryID)
                               throws ForumCategoryNotFoundException
Description copied from interface: ForumThreadService
Returns the number of threads in the specified category.

Specified by:
getThreadCountByCategoryID in interface ForumThreadService
Parameters:
categoryID - The ID of the category to check the thread count for.
Returns:
The number of threads in the category.
Throws:
ForumCategoryNotFoundException

getThreadCountByCategoryIDAndFilter

public int getThreadCountByCategoryIDAndFilter(long CategoryID,
                                               ResultFilter filter)
                                        throws ForumCategoryNotFoundException
Description copied from interface: ForumThreadService
Returns the number of threads in the specified category after being filtered by the specified filter.

Specified by:
getThreadCountByCategoryIDAndFilter in interface ForumThreadService
Parameters:
CategoryID - The ID of the category to check the thread count for.
filter - The filter to filter out results with.
Returns:
The number of threads in the category after the filter has been applied.
Throws:
ForumCategoryNotFoundException

deleteThread

public void deleteThread(long threadID)
                  throws ForumThreadNotFoundException
Description copied from interface: ForumThreadService
Deletes a thread with the specified ID.

Specified by:
deleteThread in interface ForumThreadService
Parameters:
threadID - The ID of thread to delete.
Throws:
ForumThreadNotFoundException

moveThread

public void moveThread(long threadID,
                       long forumID)
                throws ForumThreadNotFoundException,
                       ForumNotFoundException
Description copied from interface: ForumThreadService
Moves the thread with the specified ID to the forum with the specified ID.

Specified by:
moveThread in interface ForumThreadService
Parameters:
threadID - The ID of the thread to move.
forumID - The ID of the forum to move the thread to.
Throws:
ForumThreadNotFoundException
ForumNotFoundException

getProperties

public Property[] getProperties(long threadID)
                         throws ForumThreadNotFoundException
Description copied from interface: ForumThreadService
Returns all tbe extended properties for the thread with the specified ID.

Specified by:
getProperties in interface ForumThreadService
Parameters:
threadID - The ID of the thread to retrieve properties for.
Returns:
An array of extended properties for the thread with the given ID.
Throws:
ForumThreadNotFoundException

setProperty

public void setProperty(java.lang.String name,
                        java.lang.String value,
                        long threadID)
                 throws ForumThreadNotFoundException
Description copied from interface: ForumThreadService
Set an extended for the property for the thread with the given ID.

Specified by:
setProperty in interface ForumThreadService
Parameters:
name - The name of the property.
value - The value of the property.
threadID - The ID of the thread to set an extended property for.
Throws:
ForumThreadNotFoundException

getProperty

public java.lang.String getProperty(java.lang.String name,
                                    long threadID)
                             throws ForumThreadNotFoundException
Description copied from interface: ForumThreadService
Returns the value of an extended property for the thread with the specified ID.

Specified by:
getProperty in interface ForumThreadService
Parameters:
name - The name of the propery.
threadID - The ID of the thread to retrieve the property for.
Returns:
the value of the property, null if not found for the given thread ID.
Throws:
ForumThreadNotFoundException

deleteProperty

public void deleteProperty(java.lang.String name,
                           long threadID)
                    throws ForumThreadNotFoundException
Description copied from interface: ForumThreadService
Delete a property with the given name from the thread with the given ID.

Specified by:
deleteProperty in interface ForumThreadService
Parameters:
name - The name of the property to delete.
threadID - The ID of the thread to delete the property from.
Throws:
ForumThreadNotFoundException

Jive Forums Project Page

Copyright © 1999-2006 Jive Software.