org.figure8.join.businessobjects.reporting
Class MailingList

java.lang.Object
  extended by org.figure8.join.core.EntityObject
      extended by org.figure8.join.businessobjects.reporting.MailingList
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable

public class MailingList
extends EntityObject

A mailing list is used for reporting when a defined event happened within process for a defined element of domain model. It allows to specify templates for message titles and contents, overriding those defined for the type of event this list is dedicated to. A list also offers access to user's subscriptions.

Version:
$Revision: 1.3 $
Author:
Laurent Broudoux
See Also:
Serialized Form

Constructor Summary
MailingList()
          Creates a new instance of MailingList
MailingList(java.lang.String name, java.lang.String msgTitleTemplate, java.lang.String msgContentTemplate, Event event)
          Creates a new instance of MalingList with mandatory attributes
 
Method Summary
 void addSubscription(Subscription subscription)
          Convenient method for adding a subscription to this list (will ensure that subscription list is correctly set)
 Event getEvent()
           
 java.lang.String getMsgContentTemplate()
           
 java.lang.String getMsgTitleTemplate()
           
 java.lang.String getName()
           
 java.lang.String getResourceId()
           
 java.util.List getSubscriptions()
           
 boolean isGlobalMailingList()
           
 boolean isResourceMailingList()
           
 void setEvent(Event event)
           
 void setMsgContentTemplate(java.lang.String msgContentTemplate)
           
 void setMsgTitleTemplate(java.lang.String msgTitleTemplate)
           
 void setName(java.lang.String name)
           
 void setResourceId(java.lang.String resourceId)
           
 void setSubscriptions(java.util.List subscriptions)
           
 
Methods inherited from class org.figure8.join.core.EntityObject
clone, equals, getId, hashCode, isTransient
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MailingList

public MailingList()
Creates a new instance of MailingList


MailingList

public MailingList(java.lang.String name,
                   java.lang.String msgTitleTemplate,
                   java.lang.String msgContentTemplate,
                   Event event)
Creates a new instance of MalingList with mandatory attributes

Parameters:
name - The name identifying this list
msgTitleTemplate - A template for generating messages title
msgContentTemplate - A template for generating messages content
event - The type of event this mailing list is dedicated to
Method Detail

getName

public java.lang.String getName()
Returns:
The name identifying this mailing list

setName

public void setName(java.lang.String name)
Parameters:
name - The name identifying this mailing list

getMsgTitleTemplate

public java.lang.String getMsgTitleTemplate()
Returns:
A string representing template for generating messages title

setMsgTitleTemplate

public void setMsgTitleTemplate(java.lang.String msgTitleTemplate)
Parameters:
msgTitleTemplate - String representing template for title generation

getMsgContentTemplate

public java.lang.String getMsgContentTemplate()
Returns:
A string representing template for generating messages content

setMsgContentTemplate

public void setMsgContentTemplate(java.lang.String msgContentTemplate)
Parameters:
msgContentTemplate - String representing template for generating messages content

getSubscriptions

public java.util.List getSubscriptions()
Returns:
A set of Subscription objects for this mailing list

setSubscriptions

public void setSubscriptions(java.util.List subscriptions)
Parameters:
subscriptions - A set of Subscription objects for this mailing list

addSubscription

public void addSubscription(Subscription subscription)
Convenient method for adding a subscription to this list (will ensure that subscription list is correctly set)

Parameters:
subscription - The subscription to add

getEvent

public Event getEvent()
Returns:
The type of event this message is dedicated to

setEvent

public void setEvent(Event event)
Parameters:
event - The type of event this mailing list is dedicated to

getResourceId

public java.lang.String getResourceId()
Returns:
The identifier of the resource to whom this mailing list applies

setResourceId

public void setResourceId(java.lang.String resourceId)
Parameters:
resourceId - The identifier of the resource to whom this mailing list applies

isGlobalMailingList

public boolean isGlobalMailingList()
Returns:
true if this MailingList doesn't apply to a specific resource

isResourceMailingList

public boolean isResourceMailingList()
Returns:
true if this MailingList applies to a specific resource


Copyright © 2005-2008 Join. All Rights Reserved.