public class JCRCalendar extends DefaultTraversableAmetysObject<JCRCalendarFactory> implements ModifiableCalendar
Calendar
, backed by a JCR node.Calendar.CalendarVisibility
Modifier and Type | Field and Description |
---|---|
static String |
APPLICATION_ID
application id for resources collections.
|
static String |
CALENDAR_COLOR
Constants for color Calendar*
|
static String |
CALENDAR_DESC
Constants for description Calendar*
|
static String |
CALENDAR_TEMPLATE_DESC
Constants for template description Calendar*
|
static String |
CALENDAR_TITLE
Constants for title Calendar*
|
static String |
CALENDAR_VISIBILITY
Constants for color Visibility*
|
static String |
CALENDAR_WORKFLOW_NAME
Constants for workflowName Calendar*
|
Constructor and Description |
---|
JCRCalendar(Node node,
String parentPath,
JCRCalendarFactory factory)
Creates an
JCRCalendar . |
Modifier and Type | Method and Description |
---|---|
String |
getApplicationId()
Returns the application id corresponding to this Node.
|
String |
getColor()
Get the color of the calendar
|
String |
getDescription()
Get the description of the application
|
Map<CalendarEvent,List<Date>> |
getEvents(Date startDate,
Date endDate)
Get the events and its occurrences of the calendar between two dates
|
String |
getExplorerPath()
Returns the path of this explorer node in the explorer hierarchy (which is a subset of the whole repository).
If this collection is the root explorer node, "" is returned. |
String |
getIconCls()
Returns the icon css class for this Node.
|
String |
getTemplateDescription()
Get the template description of the calendar
|
Calendar.CalendarVisibility |
getVisibility()
Get the calendar visibility
|
String |
getWorkflowName()
Get the name of the workflow of the calendar
|
boolean |
hasChildExplorerNodes()
Returns true if this explorer node contains child explorer nodes.
|
void |
setColor(String color)
set the color of the calendar
|
void |
setDescription(String desc)
set the description of the calendar
|
void |
setTemplateDescription(String templateDesc)
set the template description of the calendar
|
void |
setVisibility(Calendar.CalendarVisibility visibility)
Set the visibility of the calendar
|
void |
setWorkflowName(String workflowName)
set the name of the workflow of the calendar
|
addAllowedGroups, addAllowedProfilesForAnonymous, addAllowedProfilesForAnyConnectedUser, addAllowedUsers, addDeniedGroups, addDeniedProfilesForAnonymous, addDeniedProfilesForAnyConnectedUser, addDeniedUsers, createChild, getAllowedGroups, getAllowedProfilesForAnonymous, getAllowedProfilesForAnyConnectedUser, getAllowedProfilesForGroups, getAllowedProfilesForUser, getAllowedProfilesForUsers, getAllowedUsers, getChild, getChildren, getDeniedGroups, getDeniedProfilesForAnonymous, getDeniedProfilesForAnyConnectedUser, getDeniedProfilesForGroups, getDeniedProfilesForUser, getDeniedProfilesForUsers, getDeniedUsers, hasChild, removeAllowedGroups, removeAllowedGroups, removeAllowedProfilesForAnonymous, removeAllowedProfilesForAnyConnectedUser, removeAllowedUsers, removeAllowedUsers, removeDeniedGroups, removeDeniedGroups, removeDeniedProfilesForAnonymous, removeDeniedProfilesForAnyConnectedUser, removeDeniedUsers, removeDeniedUsers
_getFactory, _invalidateName, _invalidateParentPath, getId, getMetadataHolder, getName, getNode, getParent, getParentPath, getPath, needsSave, remove, rename, revertChanges, saveChanges
equals, hashCode, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
createChild
getChild, getChildAt, getChildPosition, getChildren, hasChild
remove
needsSave, rename, revertChanges, saveChanges
equals, getId, getName, getParent, getParentPath, getPath, hashCode
getNode
getMetadataHolder
public static final String APPLICATION_ID
public static final String CALENDAR_TITLE
public static final String CALENDAR_DESC
public static final String CALENDAR_COLOR
public static final String CALENDAR_VISIBILITY
public static final String CALENDAR_WORKFLOW_NAME
public static final String CALENDAR_TEMPLATE_DESC
public JCRCalendar(Node node, String parentPath, JCRCalendarFactory factory)
JCRCalendar
.node
- the node backing this AmetysObject
parentPath
- the parentPath in the Ametys hierarchyfactory
- the DefaultAmetysObjectFactory which created the AmetysObjectpublic String getIconCls()
ExplorerNode
getIconCls
in interface ExplorerNode
public String getApplicationId()
ExplorerNode
getApplicationId
in interface ExplorerNode
public String getExplorerPath()
ExplorerNode
getExplorerPath
in interface ExplorerNode
public String getDescription()
ExplorerNode
getDescription
in interface ExplorerNode
public String getColor()
Calendar
public Calendar.CalendarVisibility getVisibility()
Calendar
getVisibility
in interface Calendar
public String getWorkflowName()
Calendar
getWorkflowName
in interface Calendar
public String getTemplateDescription()
Calendar
getTemplateDescription
in interface Calendar
public Map<CalendarEvent,List<Date>> getEvents(Date startDate, Date endDate)
Calendar
public void setDescription(String desc)
ModifiableCalendar
setDescription
in interface ModifiableCalendar
setDescription
in interface ModifiableExplorerNode
desc
- The descriptionpublic void setColor(String color)
ModifiableCalendar
setColor
in interface ModifiableCalendar
color
- The color to setpublic void setVisibility(Calendar.CalendarVisibility visibility)
ModifiableCalendar
setVisibility
in interface ModifiableCalendar
visibility
- The visibilitypublic void setWorkflowName(String workflowName)
ModifiableCalendar
setWorkflowName
in interface ModifiableCalendar
workflowName
- The workflow namepublic void setTemplateDescription(String templateDesc)
ModifiableCalendar
setTemplateDescription
in interface ModifiableCalendar
templateDesc
- The template descriptionpublic boolean hasChildExplorerNodes() throws AmetysRepositoryException
ExplorerNode
hasChildExplorerNodes
in interface ExplorerNode
AmetysRepositoryException
- if an error occurs.