public class NotificationContact
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
private static long |
serialVersionUID
The class' serialization version id.
|
Constructor and Description |
---|
NotificationContact() |
Modifier and Type | Method and Description |
---|---|
static boolean |
createContact(User user)
Creates a new contact in the notification framework.
|
static boolean |
deleteContact(User user)
Deletes an existing contact in the notification framework.
|
static java.lang.String |
getPushTopic(User user)
Returns a user's push notification topic.
|
protected static boolean |
setContactPrefs(User user)
Sets an existing contact's notification preferences in the notification
framework.
|
static boolean |
setContactPrefs(User user,
java.util.ArrayList<NotificationPref> nfprefs)
Sets an existing contact's notification preferences in the notification
framework.
|
static boolean |
setContactPrefs(User user,
NotificationPref nfpref)
Sets an existing contact's notification preferences in the notification
framework.
|
static boolean |
updateContact(User user)
Updates an existing contact in the notification framework.
|
private static final long serialVersionUID
public static final boolean createContact(User user)
user
- (User) The user on which the contact is based.true
if the processing was successful,
otherwise false
.public static final boolean deleteContact(User user)
user
- (User) The user on which the contact is based.true
if the delete was successful,
otherwise false
.public static final boolean updateContact(User user)
user
- (User) The user on which the contact is based.true
if the processing was successful,
otherwise false
.public static final java.lang.String getPushTopic(User user)
user
- (User) The user on which a contact is based.protected static final boolean setContactPrefs(User user)
This method is automatically invoked by createContact() after a new contact is successfully created.
user
- (User) The user associated with the preferences.true
if the processing was successful,
otherwise false
.public static final boolean setContactPrefs(User user, NotificationPref nfpref)
user
- (User) The user associated with the preferences.nfpref
- (NotificationPref) A notification preference object.true
if the processing was successful,
otherwise false
.public static final boolean setContactPrefs(User user, java.util.ArrayList<NotificationPref> nfprefs)
user
- (User) The user associated with the preferences.nfprefs
- (ArrayList) A collection of notification preference
objects.true
if the processing was successful,
otherwise false
.