com.arsdigita.forum
Class ThreadSubscription

java.lang.Object
  extended bycom.arsdigita.domain.DomainObject
      extended bycom.arsdigita.domain.ObservableDomainObject
          extended bycom.arsdigita.kernel.ACSObject
              extended bycom.arsdigita.notification.BaseSubscription
                  extended bycom.arsdigita.forum.Subscription
                      extended bycom.arsdigita.forum.ThreadSubscription

public class ThreadSubscription
extends Subscription

Experimental Class for managing subscriptions to individual threads in a Forum.

Author:
Kevin Scaldeferri (kevin@arsdigita.com)

Field Summary
static String BASE_DATA_OBJECT_TYPE
           
 
Fields inherited from class com.arsdigita.forum.Subscription
versionId
 
Fields inherited from class com.arsdigita.notification.BaseSubscription
ALERT_BLURB, REPLY_BLURB, SEPARATOR
 
Fields inherited from class com.arsdigita.kernel.ACSObject
CONTAINER, DEFAULT_DOMAIN_CLASS, DISPLAY_NAME, ID, OBJECT_TYPE
 
Constructor Summary
ThreadSubscription()
           
ThreadSubscription(BigDecimal id)
           
ThreadSubscription(com.arsdigita.persistence.DataObject dataObj)
           
ThreadSubscription(com.arsdigita.persistence.OID oid)
           
ThreadSubscription(String objectType)
           
 
Method Summary
protected  void afterSave()
           
protected  void beforeDelete()
          Delete all notifications sent with the sender being the group associated with this subscription.
 void doWriteCheck()
           
protected  String getBaseDataObjectType()
           
 String getSignature(Post post)
          Returns a signature with information about replying to the message
static com.arsdigita.domain.DomainCollection getSubsForUser(com.arsdigita.kernel.Party party)
           
 Post getThread()
          Deprecated. the return type of this method will soon become MessageThread
 com.arsdigita.messaging.MessageThread getThreadReal()
           
static ThreadSubscription getThreadSubscription(com.arsdigita.messaging.MessageThread thread)
           
static ThreadSubscription getThreadSubscription(Post post)
          Deprecated.  
 void setThread(com.arsdigita.messaging.MessageThread thread)
           
 void setThread(Post post)
          Deprecated.  
 
Methods inherited from class com.arsdigita.forum.Subscription
getHeader, getReturnURLMessage, getSignature
 
Methods inherited from class com.arsdigita.notification.BaseSubscription
getGroup, isSubscribed, sendNotification, setGroup, setGroupName, setupSubscriptionGroup, subscribe, unsubscribe
 
Methods inherited from class com.arsdigita.kernel.ACSObject
assertPrivilege, beforeSave, checkPrivilege, doCreateCheck, getContainer, getDefaultDomainClass, getDisplayName, getID, getSpecificObjectType, getSpecificOID, gimmeContainer, initialize, isContainerModified, setID, setID
 
Methods inherited from class com.arsdigita.domain.ObservableDomainObject
addObserver, getObservers
 
Methods inherited from class com.arsdigita.domain.DomainObject
add, add, addToAssociation, afterDelete, clear, delete, disconnect, equals, get, getObjectType, getOID, getSession, hashCode, isDeleted, isDisconnected, isModified, isNew, isPropertyModified, isValid, remove, remove, remove, removeFromAssociation, save, set, setAssociation, setAssociation, specializeDataObject, specializeDataObject, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

BASE_DATA_OBJECT_TYPE

public static final String BASE_DATA_OBJECT_TYPE
See Also:
Constant Field Values
Constructor Detail

ThreadSubscription

public ThreadSubscription()

ThreadSubscription

public ThreadSubscription(String objectType)

ThreadSubscription

public ThreadSubscription(com.arsdigita.persistence.DataObject dataObj)

ThreadSubscription

public ThreadSubscription(com.arsdigita.persistence.OID oid)
                   throws com.arsdigita.domain.DataObjectNotFoundException

ThreadSubscription

public ThreadSubscription(BigDecimal id)
                   throws com.arsdigita.domain.DataObjectNotFoundException
Method Detail

getBaseDataObjectType

protected String getBaseDataObjectType()

getThread

public Post getThread()
Deprecated. the return type of this method will soon become MessageThread


getThreadReal

public com.arsdigita.messaging.MessageThread getThreadReal()

doWriteCheck

public void doWriteCheck()

setThread

public void setThread(Post post)
Deprecated.  


setThread

public void setThread(com.arsdigita.messaging.MessageThread thread)

afterSave

protected void afterSave()

beforeDelete

protected void beforeDelete()
Delete all notifications sent with the sender being the group associated with this subscription.


getThreadSubscription

public static ThreadSubscription getThreadSubscription(Post post)
Deprecated.  

Retrieves the subscription associated with a thread. Note: post must be the root of the thread.


getThreadSubscription

public static ThreadSubscription getThreadSubscription(com.arsdigita.messaging.MessageThread thread)

getSubsForUser

public static com.arsdigita.domain.DomainCollection getSubsForUser(com.arsdigita.kernel.Party party)

getSignature

public String getSignature(Post post)
Returns a signature with information about replying to the message



Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 21 2004:2348 UTC