|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.stratelia.silverpeas.notificationManager.NotificationMetaData
public class NotificationMetaData
Field Summary | |
---|---|
static String |
AFTER_MESSAGE_FOOTER_TAG
|
static String |
BEFORE_MESSAGE_FOOTER_TAG
|
protected NotificationManager |
notificationManager
|
Constructor Summary | |
---|---|
NotificationMetaData()
Default Constructor |
|
NotificationMetaData(int messageType,
String title,
Map<String,SilverpeasTemplate> templates,
String fileName)
|
|
NotificationMetaData(int messageType,
String title,
String content)
Most common used constructor |
Method Summary | |
---|---|
void |
addExternalRecipient(ExternalRecipient externalRecipient)
|
void |
addExtraMessage(String message,
String language)
|
void |
addGroupRecipient(GroupRecipient group)
Add a group recipient to group recipients |
void |
addGroupRecipients(Collection<GroupRecipient> groups)
Add group recipients to group recipients |
void |
addLanguage(String language,
String title,
String content)
|
void |
addUserRecipient(UserRecipient user)
Add a user recipient to user recipients. |
void |
addUserRecipients(Collection<UserRecipient> users)
Add a user recipient to user recipients. |
void |
addUserRecipients(UserRecipient[] users)
Add a user recipient to user recipients. |
void |
addUserRecipientsToExclude(Collection<UserRecipient> users)
Add a user recipient to user recipients to exclude |
void |
addUserRecipientsToExclude(UserRecipient[] users)
Add a user recipient to user recipients to exclude |
void |
addUserRecipientToExclude(UserRecipient user)
Add a user recipient to user recipients to exclude |
protected boolean |
displayGroup(String groupId)
|
NotificationMetaData |
displayReceiversInFooter()
Calling this method to authorize the display of the users and groups that will received the same notification in the footer of the notification message. |
NotifAction |
getAction()
|
Set<UserRecipient> |
getAllUserRecipients()
Gets the complete list of users that will receive the notification, so it takes into account users of groups. |
Set<UserRecipient> |
getAllUserRecipients(boolean updateInternalUserRecipientsToExclude)
Gets the complete list of users that will receive the notification, so it takes into account users of groups. |
String |
getComponentId()
|
String |
getContent()
Get message content |
String |
getContent(String language)
|
Date |
getDate()
Get message date |
Collection<ExternalRecipient> |
getExternalRecipients()
|
String |
getFileName()
|
Collection<GroupRecipient> |
getGroupRecipients()
Get message group recipients |
Set<String> |
getLanguages()
|
String |
getLink()
Get message link |
String |
getLinkLabel()
Get message linkLabel |
String |
getLinkLabel(String language)
|
int |
getMessageType()
Get message type |
NotificationResourceData |
getNotificationResourceData()
|
NotificationResourceData |
getNotificationResourceData(String lang)
|
String |
getOriginalExtraMessage()
|
String |
getSender()
Get message sender |
String |
getSessionId()
Get message session Id |
String |
getSource()
Get message source |
SilverpeasTemplate |
getTemplateMessageFooter(String language)
|
Map<String,SilverpeasTemplate> |
getTemplates()
|
String |
getTitle()
Get message title |
String |
getTitle(String language)
|
Collection<UserRecipient> |
getUserRecipients()
Get message user recipients |
Collection<UserRecipient> |
getUserRecipientsToExclude()
Get message user recipients to exclude |
boolean |
isAnswerAllowed()
Get answer allowed |
boolean |
isManualUserOne()
Indicates if the current NotificationMetaData concerns a manual notification between a
sender user and several user/group receivers. |
boolean |
isSendByAUser()
Indicates if the notification is sent by a Silverpeas user or by a batch treatment. |
boolean |
isSendImmediately()
|
NotificationMetaData |
manualUserNotification()
Sets that the current NotificationMetaData instance concerns a manual notification
between a sender user and several user/group receivers. |
void |
setAction(NotifAction action)
|
void |
setAnswerAllowed(boolean answerAllowed)
Set answer allowed |
void |
setComponentId(String componentId)
|
void |
setContent(String content)
Set message content |
void |
setContent(String content,
String language)
|
void |
setDate(Date date)
Set message date |
void |
setExternalRecipients(Collection<ExternalRecipient> externalRecipients)
|
void |
setFileName(String fileName)
|
void |
setGroupRecipients(Collection<GroupRecipient> groups)
Set message group recipients |
void |
setLink(Link link)
Set link |
void |
setLink(Link link,
String language)
Set link |
void |
setLink(String link)
Set message link |
void |
setMessageType(int messageType)
Set message type |
void |
setNotificationResourceData(NotificationResourceData notificationResourceData)
|
void |
setNotificationResourceData(String lang,
NotificationResourceData notificationResourceData)
|
void |
setOriginalExtraMessage(String originalExtraMessage)
|
void |
setSender(String sender)
Set message sender |
void |
setSendImmediately(boolean sendImmediately)
|
void |
setSessionId(String sessionId)
Set message session Id |
void |
setSource(String source)
Set message source |
void |
setTitle(String title)
Set message title |
void |
setTitle(String title,
String language)
|
void |
setUserRecipients(Collection<UserRecipient> users)
Set message user recipients |
void |
setUserRecipientsToExclude(Collection<UserRecipient> users)
Set message user recipients to exclude |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String BEFORE_MESSAGE_FOOTER_TAG
public static final String AFTER_MESSAGE_FOOTER_TAG
protected NotificationManager notificationManager
Constructor Detail |
---|
public NotificationMetaData()
public NotificationMetaData(int messageType, String title, String content)
messageType
- message type (NORMAL, URGENT, ...)title
- message title (=subject)content
- message content (=body)public NotificationMetaData(int messageType, String title, Map<String,SilverpeasTemplate> templates, String fileName)
Method Detail |
---|
public final void addLanguage(String language, String title, String content)
public Set<String> getLanguages()
public Map<String,SilverpeasTemplate> getTemplates()
public void setMessageType(int messageType)
messageType
- the message type to be setpublic int getMessageType()
public void setDate(Date date)
date
- the message date to be setpublic Date getDate()
public void setTitle(String title)
title
- the title to be setpublic void setTitle(String title, String language)
public String getTitle()
public String getTitle(String language)
public void setContent(String content)
content
- the content to be setpublic void setContent(String content, String language)
public String getContent()
public String getContent(String language)
public void setSource(String source)
source
- the source to be setpublic String getSource()
public void setSender(String sender)
sender
- the sender to be setpublic void setAnswerAllowed(boolean answerAllowed)
answerAllowed
- if answer allowedpublic String getSender()
public boolean isAnswerAllowed()
public void setLink(String link)
link
- the link to be setpublic String getLink()
public void setLink(Link link)
link
- the link to be setpublic void setLink(Link link, String language)
link
- the link to be setlanguage
- the language of the linkLabelpublic String getLinkLabel()
public String getLinkLabel(String language)
public void setSessionId(String sessionId)
sessionId
- the session Id to be setpublic String getSessionId()
public void setUserRecipients(Collection<UserRecipient> users)
users
- the user ids that must receive this messagepublic Collection<UserRecipient> getUserRecipients()
public void addUserRecipient(UserRecipient user)
user
- recipient that must be addedpublic void addUserRecipients(UserRecipient[] users)
users
- users to be addedpublic void addUserRecipients(Collection<UserRecipient> users)
users
- users to be addedpublic void setUserRecipientsToExclude(Collection<UserRecipient> users)
users
- the user ids that must not receive this messagepublic Collection<UserRecipient> getUserRecipientsToExclude()
public void addUserRecipientToExclude(UserRecipient user)
user
- recipient that must not be notifiedpublic void addUserRecipientsToExclude(UserRecipient[] users)
users
- recipient that must not be notifiedpublic void addUserRecipientsToExclude(Collection<UserRecipient> users)
users
- recipient that must not be notifiedpublic Collection<ExternalRecipient> getExternalRecipients()
public void setExternalRecipients(Collection<ExternalRecipient> externalRecipients)
externalRecipients
- the externalAddress to setpublic void addExternalRecipient(ExternalRecipient externalRecipient)
externalRecipient
- the externalRecipient to addpublic void setGroupRecipients(Collection<GroupRecipient> groups)
groups
- the groups that must receive this messagepublic Collection<GroupRecipient> getGroupRecipients()
public void addGroupRecipient(GroupRecipient group)
group
- group that must be addedpublic void addGroupRecipients(Collection<GroupRecipient> groups)
groups
- public String getComponentId()
public void setComponentId(String componentId)
public void addExtraMessage(String message, String language)
public String getOriginalExtraMessage()
public void setOriginalExtraMessage(String originalExtraMessage)
public String getFileName()
public void setFileName(String fileName)
public boolean isSendImmediately()
public void setSendImmediately(boolean sendImmediately)
public NotifAction getAction()
public void setAction(NotifAction action)
public void setNotificationResourceData(NotificationResourceData notificationResourceData)
public void setNotificationResourceData(String lang, NotificationResourceData notificationResourceData)
public NotificationResourceData getNotificationResourceData()
public NotificationResourceData getNotificationResourceData(String lang)
public boolean isSendByAUser()
public SilverpeasTemplate getTemplateMessageFooter(String language)
public Set<UserRecipient> getAllUserRecipients() throws NotificationManagerException
NotificationMetaData
is updated.
NotificationManagerException
public Set<UserRecipient> getAllUserRecipients(boolean updateInternalUserRecipientsToExclude) throws NotificationManagerException
updateInternalUserRecipientsToExclude
- if true, the internal container of user
recipients to exclude will be updated. This container is provided by getUserRecipientsToExclude()
. If false, nothing is done.
NotificationManagerException
protected boolean displayGroup(String groupId)
public NotificationMetaData displayReceiversInFooter()
NotificationMetaData
instance.public NotificationMetaData manualUserNotification()
NotificationMetaData
instance concerns a manual notification
between a sender user and several user/group receivers.
NotificationMetaData
instance.public boolean isManualUserOne()
NotificationMetaData
concerns a manual notification between a
sender user and several user/group receivers.
NotificationMetaData
concerns a manual one, false
otherwise.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |