Class CachedAgendaEventStorage
java.lang.Object
org.exoplatform.agenda.storage.AgendaEventStorage
org.exoplatform.agenda.storage.cached.CachedAgendaEventStorage
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionCachedAgendaEventStorage(org.exoplatform.services.cache.CacheService cacheService, CalendarDAO calendarDAO, EventDAO eventDAO, EventRecurrenceDAO eventRecurrenceDAO) -
Method Summary
Modifier and TypeMethodDescriptionvoidvoiddeleteCalendarEvents(long calendarId) voiddeleteEventAfterRead(long eventId) Deletes an event whose attendees, conferences or reminders were read in the same request, whichAgendaEventStorage.deleteEventById(long)cannot: the persistence context is cleared before the bulk deletion of its children.voiddeleteEventById(long eventId) deleteExceptionalOccurences(long parentRecurrentEventId) org.exoplatform.agenda.model.EventgetEventById(long eventId) moveCalendarEvents(long fromCalendarId, long toCalendarId) Moves all events of a calendar to another calendar, keeping every event and its associated data (attendees, reminders, conferences, recurrences, remote identifiers) untouched apart from the calendar membership.org.exoplatform.agenda.model.EventupdateEvent(org.exoplatform.agenda.model.Event event) Methods inherited from class org.exoplatform.agenda.storage.AgendaEventStorage
countEventDatePolls, countPendingEvents, createEvent, getEventDatePollIds, getEventDatePollIds, getEventIds, getExceptionalOccurenceIds, getExceptionalOccurenceIds, getExceptionalOccurenceIdsByPeriod, getExceptionalOccurrenceEvent, getParentRecurrentEventIds, getPendingEventIds, getUserEventCalenderIds, isRecurrentEvent
-
Field Details
-
EVENT_CACHE_NAME
- See Also:
-
-
Constructor Details
-
CachedAgendaEventStorage
public CachedAgendaEventStorage(org.exoplatform.services.cache.CacheService cacheService, CalendarDAO calendarDAO, EventDAO eventDAO, EventRecurrenceDAO eventRecurrenceDAO)
-
-
Method Details
-
getEventById
public org.exoplatform.agenda.model.Event getEventById(long eventId) - Overrides:
getEventByIdin classAgendaEventStorage
-
updateEvent
public org.exoplatform.agenda.model.Event updateEvent(org.exoplatform.agenda.model.Event event) - Overrides:
updateEventin classAgendaEventStorage
-
deleteEventById
public void deleteEventById(long eventId) - Overrides:
deleteEventByIdin classAgendaEventStorage
-
deleteEventAfterRead
public void deleteEventAfterRead(long eventId) Description copied from class:AgendaEventStorageDeletes an event whose attendees, conferences or reminders were read in the same request, whichAgendaEventStorage.deleteEventById(long)cannot: the persistence context is cleared before the bulk deletion of its children.- Overrides:
deleteEventAfterReadin classAgendaEventStorage- Parameters:
eventId- the event to delete
-
deleteCalendarEvents
public void deleteCalendarEvents(long calendarId) - Overrides:
deleteCalendarEventsin classAgendaEventStorage
-
moveCalendarEvents
Moves all events of a calendar to another calendar, keeping every event and its associated data (attendees, reminders, conferences, recurrences, remote identifiers) untouched apart from the calendar membership. In addition, evicts the moved events from the event cache so that subsequent reads return the new calendar membership.- Overrides:
moveCalendarEventsin classAgendaEventStorage- Parameters:
fromCalendarId- technical identifier of the calendar the events are moved away fromtoCalendarId- technical identifier of the calendar receiving the events- Returns:
Listof technical identifiers of the moved events, empty when the source calendar had no events
-
deleteExceptionalOccurences
- Overrides:
deleteExceptionalOccurencesin classAgendaEventStorage
-
clearCache
public void clearCache()
-