Class CalendarExtensions
OptimaJet.Workflow.Core.Runtime.Calendars.CalendarExtensions
Namespace: OptimaJet.Workflow.Core.Runtime.Calendars
public static class CalendarExtensionsInheritance
- System.Object
Methods
public static TimeSpan GetInterval(this ICalendar calendar, string value, DateTime startDateTime) #Calculate the time interval
Parameters
Name
Type
Description
calendarICalendarCalendar instance
valueStringString with a timer value
startDateTimeDateTimeDate and time of the start of the countdown
Returns
Type
Description
TimeSpanTimeSpan with interval
public static Calendar SetWorkingHours(this Calendar calendar, TimeSpan workingHours) #Set working hours per day
Parameters
Name
Type
Description
calendarCalendarCalendar instance
workingHoursTimeSpanWorking hours
Returns
Type
Description
CalendarCalendar instance
public static Calendar SetStartOfWork(this Calendar calendar, TimeSpan startTimeOfDay) #Set the start of the work day
Parameters
Name
Type
Description
calendarCalendarCalendar instance
startTimeOfDayTimeSpanThe beginning of the work day
Returns
Type
Description
CalendarCalendar instance
public static Calendar SetWeekends(this Calendar calendar, params DayOfWeek[] weekends) #Set the weekends
Parameters
Name
Type
Description
calendarCalendarCalendar instance
weekendsDayOfWeek[]Array of the DayOfWeek
Returns
Type
Description
CalendarCalendar instance