Class CatalogueEvent
- java.lang.Object
-
- org.gcube.social_networking.socialnetworking.model.beans.catalogue.CatalogueEvent
-
public class CatalogueEvent extends Object
The CatalogueEvent super class
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanidsAsGroupoptionl field, set to true if the idsToNotify are contexts, default is falseprotected String[]idsToNotifythe username of the user you wish to notifyprotected StringitemIdthe item identifier or name (it is used in the subject of the email)protected URLitemURLthe URL to redirect when clicking on the notificationprotected StringnotifyTextthe text that you want to write in the notification (text/plain format)protected CatalogueEventTypetype
-
Constructor Summary
Constructors Constructor Description CatalogueEvent()CatalogueEvent(CatalogueEventType type, String[] idsToNotify, String itemId, String notifyText, URL itemURL)for sending to usersCatalogueEvent(CatalogueEventType type, String[] idsToNotify, String itemId, String notifyText, URL itemURL, boolean idsAsGroup)for sending to users or groups
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String[]getIdsToNotify()StringgetItemId()URLgetItemURL()StringgetNotifyText()CatalogueEventTypegetType()booleanidsAsGroup()booleanisIdsAsGroup()voidsetIdsAsGroup(boolean idsAsGroup)voidsetIdsToNotify(String[] idsToNotify)voidsetItemId(String itemId)voidsetItemURL(URL itemURL)voidsetNotifyText(String notifyText)voidsetType(CatalogueEventType type)StringtoString()
-
-
-
Field Detail
-
type
protected CatalogueEventType type
-
idsToNotify
@NotNull(message="recipients cannot be missing, use usernames or contexts") protected String[] idsToNotify
the username of the user you wish to notify
-
itemId
@NotNull(message="itemId cannot be missing") protected String itemId
the item identifier or name (it is used in the subject of the email)
-
notifyText
@NotNull(message="notifyText cannot be missing") protected String notifyText
the text that you want to write in the notification (text/plain format)
-
itemURL
@NotNull(message="itemURL cannot be missing, use catalogue resolver URL") protected URL itemURL
the URL to redirect when clicking on the notification
-
idsAsGroup
@DefaultValue("false") protected boolean idsAsGroupoptionl field, set to true if the idsToNotify are contexts, default is false
-
-
Constructor Detail
-
CatalogueEvent
public CatalogueEvent()
-
CatalogueEvent
public CatalogueEvent(CatalogueEventType type, String[] idsToNotify, String itemId, String notifyText, URL itemURL, boolean idsAsGroup)
for sending to users or groups- Parameters:
type-idsToNotify-itemId-notifyText-itemURL-idsAsGroup-
-
CatalogueEvent
public CatalogueEvent(CatalogueEventType type, String[] idsToNotify, String itemId, String notifyText, URL itemURL)
for sending to users- Parameters:
type-idsToNotify-itemId-notifyText-itemURL-
-
-
Method Detail
-
getType
public CatalogueEventType getType()
-
setType
public void setType(CatalogueEventType type)
-
getIdsToNotify
public String[] getIdsToNotify()
-
setIdsToNotify
public void setIdsToNotify(String[] idsToNotify)
-
idsAsGroup
public boolean idsAsGroup()
- Returns:
- true whether the idsToNotify have to be interpreted as groups and not usernames
-
setIdsAsGroup
public void setIdsAsGroup(boolean idsAsGroup)
- Parameters:
idsAsGroup- set true whether the idsToNotify have to be interpreted as groups and not usernames, false otherwise
-
getItemId
public String getItemId()
-
setItemId
public void setItemId(String itemId)
-
getNotifyText
public String getNotifyText()
-
setNotifyText
public void setNotifyText(String notifyText)
-
getItemURL
public URL getItemURL()
-
setItemURL
public void setItemURL(URL itemURL)
-
isIdsAsGroup
public boolean isIdsAsGroup()
-
-