Class NotificationInfo
- java.lang.Object
-
- org.exoplatform.commons.api.notification.model.NotificationInfo
-
public class NotificationInfo extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static StringFOR_ALL_INTERNAL_USERstatic StringFOR_ALL_USERstatic StringPREFIX_ID
-
Constructor Summary
Constructors Constructor Description NotificationInfo()
-
Method Summary
-
-
-
Field Detail
-
PREFIX_ID
public static final String PREFIX_ID
- See Also:
- Constant Field Values
-
FOR_ALL_USER
public static final String FOR_ALL_USER
- See Also:
- Constant Field Values
-
FOR_ALL_INTERNAL_USER
public static final String FOR_ALL_INTERNAL_USER
- See Also:
- Constant Field Values
-
-
Method Detail
-
instance
public static NotificationInfo instance()
-
getId
public String getId()
-
setId
public NotificationInfo setId(String id)
-
setSendAll
public NotificationInfo setSendAll(boolean isSendAll)
-
isSendAll
public boolean isSendAll()
-
isSendAllInternals
public boolean isSendAllInternals()
-
setSendAllInternals
public NotificationInfo setSendAllInternals(boolean isSendAllInternals)
-
isUpdate
public boolean isUpdate()
-
setUpdate
public NotificationInfo setUpdate(boolean isUpdate)
-
getKey
public PluginKey getKey()
-
key
public NotificationInfo key(PluginKey key)
-
key
public NotificationInfo key(String id)
-
getFrom
public String getFrom()
-
setFrom
public NotificationInfo setFrom(String from)
-
getTitle
public String getTitle()
Gets the title of the notification- Returns:
-
setTitle
public NotificationInfo setTitle(String title)
Sets the title of the notification- Parameters:
title-
-
getChannelKey
public ChannelKey getChannelKey()
Gets the channel key of the notification- Returns:
-
setChannelKey
public void setChannelKey(ChannelKey channelKey)
Sets the channel of the notification- Parameters:
channelKey-
-
getTo
public String getTo()
- Returns:
- the to
-
setTo
public NotificationInfo setTo(String to)
- Parameters:
to- the to to set
-
getOrder
public int getOrder()
- Returns:
- the order
-
setOrder
public NotificationInfo setOrder(int order)
- Parameters:
order- the order to set
-
to
public NotificationInfo to(List<String> sendToUserIds)
-
to
public NotificationInfo to(String sendToUserId)
-
exclude
public NotificationInfo exclude(List<String> excludedUsersIds)
-
exclude
public NotificationInfo exclude(String excludedUserId)
-
isExcluded
public boolean isExcluded(String userId)
-
getValueOwnerParameter
public String getValueOwnerParameter(String key)
- Returns:
- the value of ownerParameter
-
getArrayOwnerParameter
public String[] getArrayOwnerParameter()
- Returns:
- the array ownerParameter
-
setOwnerParameter
public NotificationInfo setOwnerParameter(Map<String,String> ownerParameter)
- Parameters:
ownerParameter- the ownerParameter to set
-
with
public NotificationInfo with(String key, String value)
- Parameters:
key- the ownerParameter key to setvalue- the ownerParameter value to set
-
end
public NotificationInfo end()
-
getLastModifiedDate
public long getLastModifiedDate()
Get the last modified date- Returns:
-
setLastModifiedDate
public NotificationInfo setLastModifiedDate(Calendar lastModifiedDate)
- Parameters:
lastModifiedDate-
-
setLastModifiedDate
public NotificationInfo setLastModifiedDate(long lastModifiedDate)
- Parameters:
lastModifiedDate-
-
getDateCreated
public Calendar getDateCreated()
-
setDateCreated
public NotificationInfo setDateCreated(Calendar dateCreated)
-
isOnPopOver
public boolean isOnPopOver()
-
setOnPopOver
public NotificationInfo setOnPopOver(boolean isOnPopOver)
-
getSendToDaily
public String[] getSendToDaily()
- Returns:
- the sendToDaily
-
setSendToDaily
public NotificationInfo setSendToDaily(String[] userIds)
- Parameters:
userIds- the list userIds to set for sendToDaily
-
setSendToDaily
public NotificationInfo setSendToDaily(String userId)
- Parameters:
userId- the userId to add into sendToDaily
-
removeOnSendToDaily
public NotificationInfo removeOnSendToDaily(String userId)
- Parameters:
userId- the userId to remove into sendToDaily
-
getSendToWeekly
public String[] getSendToWeekly()
- Returns:
- the sendToWeekly
-
setSendToWeekly
public NotificationInfo setSendToWeekly(String[] userIds)
- Parameters:
userIds- the list userIds to set for sendToWeekly
-
setSendToWeekly
public NotificationInfo setSendToWeekly(String userId)
- Parameters:
userId- the userId to add into sendToWeekly
-
removeOnSendToWeekly
public NotificationInfo removeOnSendToWeekly(String userId)
- Parameters:
userId- the userId to remove into sendToWeekly
-
isResetOnBadge
public boolean isResetOnBadge()
-
setResetOnBadge
public NotificationInfo setResetOnBadge(boolean resetOnBadge)
-
isRead
public boolean isRead()
-
setRead
public NotificationInfo setRead(boolean read)
-
clone
public NotificationInfo clone()
-
clone
public NotificationInfo clone(boolean isNew)
-
getIdGeneratorService
public static org.exoplatform.services.idgenerator.IDGeneratorService getIdGeneratorService()
-
generate
public static String generate()
-
-