Class UserSetting
java.lang.Object
org.exoplatform.commons.api.notification.model.UserSetting
User setting notification
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddChannelPlugin(String channelId, String pluginId) Add the pluginId by channelvoidaddPlugin(String pluginId, UserSetting.FREQUENCY frequencyType) clone()booleanstatic UserSettinglonggetPlugins(String channelId) inthashCode()booleanChecks the user's setting for the channel and the plugin if it's active, it's instantly including the email channel.booleanisChannelActive(String channelId, String pluginId) booleanisChannelGloballyActive(String channelId) booleanbooleanbooleanisInWeekly(String pluginId) voidremoveChannelActive(String channelId) voidremoveChannelPlugin(String channelId, String pluginId) remove the pluginId on channelvoidremovePlugin(String pluginId, UserSetting.FREQUENCY frequencyType) voidsetAllChannelPlugins(Map<String, List<String>> channelPlugins) voidsetChannelActive(String channelId) voidsetChannelActives(Set<String> channelActives) voidsetChannelPlugins(String channelId, List<String> pluginIds) voidsetDailyPlugins(List<String> dailyPlugins) voidsetEnabled(boolean isEnabled) voidsetLastReadDate(long lastReadDate) setLastUpdateTime(Calendar lastUpdateTime) voidsetWeeklyPlugins(List<String> weeklyPlugins) toString()
-
Field Details
-
EMAIL_CHANNEL
- See Also:
-
-
Constructor Details
-
UserSetting
public UserSetting()
-
-
Method Details
-
getInstance
-
getLastReadDate
public long getLastReadDate() -
setLastReadDate
public void setLastReadDate(long lastReadDate) -
getChannelActives
-
isChannelGloballyActive
-
isChannelActive
-
setChannelActive
-
removeChannelActive
-
setChannelActives
-
getUserId
-
setUserId
-
getLastUpdateTime
-
setLastUpdateTime
-
setAllChannelPlugins
-
getAllChannelPlugins
-
getPlugins
-
setChannelPlugins
-
addChannelPlugin
Add the pluginId by channel- Parameters:
channelId- Channel identifierpluginId- Plugin identifier
-
removeChannelPlugin
remove the pluginId on channel- Parameters:
channelId- Channel identifierpluginId- Plugin identifier
-
getDailyPlugins
- Returns:
- the dailyPlugins
-
setDailyPlugins
- Parameters:
dailyPlugins- the dailyPlugins to set
-
getWeeklyPlugins
- Returns:
- the weeklyPlugins
-
setWeeklyPlugins
- Parameters:
weeklyPlugins- the weeklyPlugins to set
-
addPlugin
- Parameters:
pluginId- the provider's id to addfrequencyType-UserSetting.FREQUENCYof notification plugin
-
removePlugin
-
isActive
Checks the user's setting for the channel and the plugin if it's active, it's instantly including the email channel.- Parameters:
channelId- Channel identifierpluginId- Plugin identifier- Returns:
- true if active, else false
-
isInDaily
-
isInWeekly
-
clone
-
toString
-
isEnabled
public boolean isEnabled() -
setEnabled
public void setEnabled(boolean isEnabled) -
equals
-
hashCode
public int hashCode()
-