Jive Forums API (5.5.20.2-oracle) Developer Javadocs

com.jivesoftware.forum
Interface ContentRetrieval

All Known Subinterfaces:
ForumCategory
All Known Implementing Classes:
DbForumCategory, ForumCategoryProxy

public interface ContentRetrieval

Interface for accessing threads, messages, documents, and blog posts - all the fundamental content elements in the system. The object implementing this interface can either be the logical container of those content elements (like a ForumCategory)).

See Also:
ForumCategory

Field Summary
static long[] ALL_TYPES
          An array of all ContentTypes
static long THREAD
           
 
Method Summary
 java.util.Iterator getCombinedContent(long[] types)
          Returns an Iterable for all threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument.
 java.util.Iterator getCombinedContent(ResultFilter filter, long[] types)
          Returns an Iterable for all threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument, and according the the supplied ResultFilter.
 int getCombinedContentCount(long[] types)
          Returns the combined number of threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument.
 int getCombinedContentCount(ResultFilter filter, long[] types)
          Returns the combined number of threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument, and restricted by the ResultFilter.
 int getMessageCount()
          Returns the number of messages in the community.
 int getMessageCount(ResultFilter filter)
          Returns the number of messages in the community based on the specified ResultFilter.
 java.util.Iterator getMessages()
          Returns an Iterable for all the messages in the community.
 java.util.Iterator getMessages(ResultFilter filter)
          Returns an Iterable for all the messages in the community that match the criteria specified by the ResultFilter.
 int getThreadCount()
          Returns the number of threads in the community.
 int getThreadCount(ResultFilter resultFilter)
          Returns the number of threads in the community based on the specified ResultFilter.
 java.util.Iterator getThreads()
          Returns an Iterable for all the threads in the community.
 java.util.Iterator getThreads(ResultFilter resultFilter)
          Returns an Iterable for all the threads in the community that match the criteria specified by the ResultFilter.
 

Field Detail

THREAD

static final long THREAD
See Also:
Constant Field Values

ALL_TYPES

static final long[] ALL_TYPES
An array of all ContentTypes

Method Detail

getCombinedContentCount

int getCombinedContentCount(long[] types)
Returns the combined number of threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument. Note: this method ignores permissions because it's not possible to do a database query for the count that obeys permissions counts. Therefore, the count returned by this method may not be the same as the number of conten objects returned by the getCombinedContent(long[]) method.

Parameters:
types - the ContentTypes to include in the count.
Returns:
combined number of threads, documents, and blog posts in the community.

getCombinedContentCount

int getCombinedContentCount(ResultFilter filter,
                            long[] types)
Returns the combined number of threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument, and restricted by the ResultFilter. Note: this method ignores permissions because it's not possible to do a database query for the count that obeys permissions counts. Therefore, the count returned by this method may not be the same as the number of conten objects returned by the getCombinedContent(ResultFilter, long[]) method.

Parameters:
filter - the ResultFilter to filter the results.
types - the ContentTypes to include in the count.
Returns:
combined number of threads, documents, and blog posts in the community.

getCombinedContent

java.util.Iterator getCombinedContent(long[] types)
Returns an Iterable for all threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument. The results will be sorted by descending modification date.

Parameters:
types - the ContentTypes to include in the result.
Returns:
an Iterable for the threads, documents, and blog posts in the community.

getCombinedContent

java.util.Iterator getCombinedContent(ResultFilter filter,
                                      long[] types)
Returns an Iterable for all threads, documents, and blog posts in the community, depending on which ContentTypes are supplied as an argument, and according the the supplied ResultFilter.

Parameters:
filter - the ResultFilter to filter and sort the results.
types - the ContentTypes to include in the result.
Returns:
an Iterable for the threads, documents, and blog posts in the community.

getThreadCount

int getThreadCount()
Returns the number of threads in the community. Note: this method ignores permissions because it's not possible to do a database query for the count that obeys permissions counts. Therefore, the count returned by this method may not be the same as the number of threads returned by the getThreads() method.

Returns:
the number of threads in the community.

getThreadCount

int getThreadCount(ResultFilter resultFilter)
Returns the number of threads in the community based on the specified ResultFilter. This is useful for determining such things as the number of threads in a date range, etc. Note: this method ignores permissions because it's not possible to do a database query for the count that obeys permissions counts. Therefore, the count returned by this method may not be the same as the number of threads returned by the getThreads(com.jivesoftware.forum.ResultFilter) method.

Parameters:
resultFilter - a resultFilter to limit the query on.
Returns:
the number of threads in the community based on the filter.

getThreads

java.util.Iterator getThreads()
Returns an Iterable for all the threads in the community. Threads will be sorted on their modified date.

Returns:
an Iterable for the threads in the community.

getThreads

java.util.Iterator getThreads(ResultFilter resultFilter)
Returns an Iterable for all the threads in the community that match the criteria specified by the ResultFilter.

Parameters:
resultFilter - a ResultFilter object to perform filtering and sorting with.
Returns:
an Iterable for the threads in the community that match the ResultFilter.

getMessageCount

int getMessageCount()
Returns the number of messages in the community. Note: this method ignores permissions because it's not possible to do a database query for the count that obeys permissions counts. Therefore, the count returned by this method may not be the same as the number of messages returned by the getMessages() method.

Returns:
the number of messages in the community.

getMessageCount

int getMessageCount(ResultFilter filter)
Returns the number of messages in the community based on the specified ResultFilter. This is useful for determining such things as the number of messages in a date range, etc. Note: this method ignores permissions because it's not possible to do a database query for the count that obeys permissions counts. Therefore, the count returned by this method may not be the same as the number of messages returned by the getMessages(ResultFilter) method.

Parameters:
filter - a resultFilter to limit the query on.
Returns:
the number of messages in the community based on the filter.

getMessages

java.util.Iterator getMessages()
Returns an Iterable for all the messages in the community.

Returns:
an Iterable for the messages in the community.

getMessages

java.util.Iterator getMessages(ResultFilter filter)
Returns an Iterable for all the messages in the community that match the criteria specified by the ResultFilter.

Parameters:
filter - a ResultFilter object to perform filtering and sorting with.
Returns:
an Iterable for the messages in the community that match the ResultFilter.

Jive Forums Project Page

Copyright © 1999-2006 Jive Software.