Workflow Engine .NET

Assembly: OptimaJet.Workflow.Core

Class CalendarExtensions

OptimaJet.Workflow.Core.Runtime.Calendars.CalendarExtensions

public static class CalendarExtensions

Inheritance

  • System.Object

Methods

public static TimeSpan GetInterval(this ICalendar calendar, string value, DateTime startDateTime) #
Calculate the time interval

Parameters

Name
Type
Description
calendar
ICalendar
Calendar instance
value
String
String with a timer value
startDateTime
DateTime
Date and time of the start of the countdown

Returns

Type
Description
TimeSpan
TimeSpan with interval
public static Calendar SetWorkingHours(this Calendar calendar, TimeSpan workingHours) #
Set working hours per day

Parameters

Name
Type
Description
calendar
Calendar
Calendar instance
workingHours
TimeSpan
Working hours

Returns

Type
Description
Calendar
Calendar instance
public static Calendar SetStartOfWork(this Calendar calendar, TimeSpan startTimeOfDay) #
Set the start of the work day

Parameters

Name
Type
Description
calendar
Calendar
Calendar instance
startTimeOfDay
TimeSpan
The beginning of the work day

Returns

Type
Description
Calendar
Calendar instance
public static Calendar SetWeekends(this Calendar calendar, params DayOfWeek[] weekends) #
Set the weekends

Parameters

Name
Type
Description
calendar
Calendar
Calendar instance
weekends
DayOfWeek[]
Array of the DayOfWeek

Returns

Type
Description
Calendar
Calendar instance
public static Calendar SetYears(this Calendar calendar, params Year[] years) #
Set years

Parameters

Name
Type
Description
calendar
Calendar
Calendar instance
years
Year[]
Array of the Year

Returns

Type
Description
Calendar
Calendar instance