Package org.exoplatform.agenda.service
Class AgendaAvailabilityServiceImpl
java.lang.Object
org.exoplatform.agenda.service.AgendaAvailabilityServiceImpl
- All Implemented Interfaces:
org.exoplatform.agenda.service.AgendaAvailabilityService
@Service
public class AgendaAvailabilityServiceImpl
extends Object
implements org.exoplatform.agenda.service.AgendaAvailabilityService
The one place free/busy is computed, and the one place it is guarded.
See AgendaAvailabilityService for the two rules — the calendar ACL
floor and the target's own sharing setting that may widen it — and why they
live here rather than in each surface.
-
Constructor Summary
ConstructorsConstructorDescriptionAgendaAvailabilityServiceImpl(org.exoplatform.agenda.service.AgendaEventService agendaEventService, org.exoplatform.social.core.manager.IdentityManager identityManager, org.exoplatform.social.core.space.spi.SpaceService spaceService, org.exoplatform.agenda.service.AgendaUserSettingsService agendaUserSettingsService) Builds the service. -
Method Summary
Modifier and TypeMethodDescriptionList<org.exoplatform.agenda.model.UserAvailability> getAvailability(List<Long> targetIdentityIds, ZonedDateTime start, ZonedDateTime end, long userIdentityId) List<org.exoplatform.agenda.model.UserBusyTime> getBusyTime(List<Long> targetIdentityIds, ZonedDateTime start, ZonedDateTime end, long userIdentityId) org.exoplatform.agenda.model.AvailabilityConflictsgetConflicts(List<Long> attendeeIdentityIds, ZonedDateTime start, ZonedDateTime end, long userIdentityId) List<org.exoplatform.agenda.model.EventDateOption> rankDateOptionsByAvailability(List<org.exoplatform.agenda.model.EventDateOption> dateOptions, List<Long> attendeeIdentityIds, long userIdentityId) List<org.exoplatform.agenda.model.TimeBlock> suggestMeetingTime(List<Long> attendeeIdentityIds, Duration duration, ZonedDateTime windowStart, ZonedDateTime windowEnd, boolean morningsOnly, boolean afternoonsOnly, int limit, long userIdentityId)
-
Constructor Details
-
AgendaAvailabilityServiceImpl
@Autowired public AgendaAvailabilityServiceImpl(org.exoplatform.agenda.service.AgendaEventService agendaEventService, org.exoplatform.social.core.manager.IdentityManager identityManager, org.exoplatform.social.core.space.spi.SpaceService spaceService, org.exoplatform.agenda.service.AgendaUserSettingsService agendaUserSettingsService) Builds the service.- Parameters:
agendaEventService- the event service the busy times are read fromidentityManager- used to resolve the asking and target identitiesspaceService- used by the calendar ACL to resolve space membership, and to decide whether two users share a spaceagendaUserSettingsService- owner of each user's sharing choice
-
-
Method Details
-
getAvailability
public List<org.exoplatform.agenda.model.UserAvailability> getAvailability(List<Long> targetIdentityIds, ZonedDateTime start, ZonedDateTime end, long userIdentityId) throws IllegalAccessException - Specified by:
getAvailabilityin interfaceorg.exoplatform.agenda.service.AgendaAvailabilityService- Throws:
IllegalAccessException
-
getBusyTime
public List<org.exoplatform.agenda.model.UserBusyTime> getBusyTime(List<Long> targetIdentityIds, ZonedDateTime start, ZonedDateTime end, long userIdentityId) - Specified by:
getBusyTimein interfaceorg.exoplatform.agenda.service.AgendaAvailabilityService
-
suggestMeetingTime
public List<org.exoplatform.agenda.model.TimeBlock> suggestMeetingTime(List<Long> attendeeIdentityIds, Duration duration, ZonedDateTime windowStart, ZonedDateTime windowEnd, boolean morningsOnly, boolean afternoonsOnly, int limit, long userIdentityId) throws IllegalAccessException - Specified by:
suggestMeetingTimein interfaceorg.exoplatform.agenda.service.AgendaAvailabilityService- Throws:
IllegalAccessException
-
getConflicts
public org.exoplatform.agenda.model.AvailabilityConflicts getConflicts(List<Long> attendeeIdentityIds, ZonedDateTime start, ZonedDateTime end, long userIdentityId) - Specified by:
getConflictsin interfaceorg.exoplatform.agenda.service.AgendaAvailabilityService
-
rankDateOptionsByAvailability
public List<org.exoplatform.agenda.model.EventDateOption> rankDateOptionsByAvailability(List<org.exoplatform.agenda.model.EventDateOption> dateOptions, List<Long> attendeeIdentityIds, long userIdentityId) - Specified by:
rankDateOptionsByAvailabilityin interfaceorg.exoplatform.agenda.service.AgendaAvailabilityService
-