Package com.webmethods.sc.calendar
Interface ICalendarSystem
public interface ICalendarSystem
Main access point to shared business calendaring component. Instance of ICalendarSystem could be obtained from
CalendarSystemFactory
factory class. Before calling about ICalendarSystem APIs you need to initialize
MWSLibrary
MWS library component with connection to MWS database-
Method Summary
Modifier and TypeMethodDescriptiondefault void
Check for the presense of any existing pre-requisites and throws exception if the prerequisites are not present.Returns instance ofICalendarBuilder
which is used to create calendar instance objectsgetCalendarEvaluator
(Date baseDate, IWorkdayCalendar businessCalendar) Creates and returns instance ofICalendarEvaluator
which is used to perform calendar calculationsgetCalendarEvaluator
(Date baseDate, IWorkdayCalendar businessCalendar, IWorkdayCalendar userCalendar) Creates and returns instance ofICalendarEvaluator
which is used to perform calendar calculationsReturns instance ofICalendarManager
used to manage persisted calendar instances.getCalendarManager
(String userID) Returns instance ofICalendarManager
used to manage persisted calendar instances.Returns the transport that this implemenation uses to communicate to MWS
-
Method Details
-
getTransport
Transport getTransport()Returns the transport that this implemenation uses to communicate to MWS- Returns:
- the transport
-
getCalendarManager
Returns instance ofICalendarManager
used to manage persisted calendar instances.- Throws:
CalendarException
-
getCalendarManager
Returns instance ofICalendarManager
used to manage persisted calendar instances. Returned calendar manager will be active on behalf of specified user thus honoring all user assigned permissions- Parameters:
userID
- ID of the user- Throws:
CalendarException
-
getCalendarBuilder
ICalendarBuilder getCalendarBuilder()Returns instance ofICalendarBuilder
which is used to create calendar instance objects -
getCalendarEvaluator
Creates and returns instance ofICalendarEvaluator
which is used to perform calendar calculations- Parameters:
baseDate
- this is the base date for all calendar calculations. Calendar evaluator may perform calculations only in the future ranges off the baseDatebusinessCalendar
- instance ofIWorkdayCalendar
calendar to use- Returns:
- instance of
ICalendarEvaluator
-
getCalendarEvaluator
ICalendarEvaluator getCalendarEvaluator(Date baseDate, IWorkdayCalendar businessCalendar, IWorkdayCalendar userCalendar) Creates and returns instance ofICalendarEvaluator
which is used to perform calendar calculations- Parameters:
baseDate
- this is the base date for all calendar calculations. Calendar evaluator may perform calculations only in the future ranges off the baseDatebusinessCalendar
- instance ofIWorkdayCalendar
calendar to useuserCalendar
- instance of user personalIWorkdayCalendar
. Each user has two attributes "userCorporateCalendar" and "userPersonalCalendar" which values are calendar IDs for business and user calendar objects respectively assigned to the given user object (IDirectoryUser
). Knowing an ID of the business calendar the one may obtain calendar instance fromICalendarManager
- Returns:
- instance of
ICalendarEvaluator
this evaluator instance will perform calendar calculations based on the specified business calendar which defined holidays and workhours and user personal calendar which defined time off for the given user
-
checkPrerequisites
Check for the presense of any existing pre-requisites and throws exception if the prerequisites are not present.- Throws:
DirectoryException
CalendarException
-