blackboard.data.discussionboard
Class MessageCounts

java.lang.Object
  extended by blackboard.data.discussionboard.MessageCounts

public class MessageCounts
extends java.lang.Object

This object represents aggregate data for discussion board messages It contains a total count of messages and a count of read messages. There is a convenience method that will give you the count of unread messages by taking the total and subtracting the number of read messages. This object is used to store counts for: a) All messages in a forum b) All messages in a thread c) An arbitrary list of messages This is not an actual persistant object, the data is generated by queries.

Since:
Bb 7.2
Version:
$Revision: #1 $ $Date: 2007/06/27 $

Constructor Summary
MessageCounts()
           
 
Method Summary
 boolean areAllMsgsRead()
          Indicates whether all of the messages represented in this count are read.
 int getReadCount()
          Gets the number of read messages.
 int getTotalCount()
          Gets the total number of messages.
 int getUnreadCount()
          Gets the number of unread messages.
 void setReadCount(int readCount)
          Sets the number of read messages
 void setTotalCount(int totalCount)
          Sets the total number of messages.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageCounts

public MessageCounts()
Method Detail

getReadCount

public int getReadCount()
Gets the number of read messages. In a thread, this does not include the thread message itself, just its children.

Returns:

setReadCount

public void setReadCount(int readCount)
Sets the number of read messages

Parameters:
readCount -

getTotalCount

public int getTotalCount()
Gets the total number of messages. In a thread, this does not include the thread message itself, just its children.

Returns:

setTotalCount

public void setTotalCount(int totalCount)
Sets the total number of messages.

Parameters:
totalCount -

getUnreadCount

public int getUnreadCount()
Gets the number of unread messages. In a thread, this does not include the thread message itself, just its children.

Returns:

areAllMsgsRead

public boolean areAllMsgsRead()
Indicates whether all of the messages represented in this count are read.



Copyright © 2003 Blackboard, Inc. All Rights Reserved.