C# Класс GSF.Scheduling.Schedule

Represents a schedule defined using UNIX crontab syntax.

Operators:

There are several ways of specifying multiple date/time values in a field: The comma (',') operator specifies a list of values, for example: "1,3,4,7,8" The dash ('-') operator specifies a range of values, for example: "1-6", which is equivalent to "1,2,3,4,5,6" The asterisk ('*') operator specifies all possible values for a field. For example, an asterisk in the hour time field would be equivalent to 'every hour' (subject to matching other specified fields). The slash ('/') operator (called "step"), which can be used to skip a given number of values. For example, "*/3" in the hour time field is equivalent to "0,3,6,9,12,15,18,21". So "*" specifies 'every hour' but the "*/3" means only those hours divisible by 3.

Fields:

+---------------- minute (0 - 59) | +------------- hour (0 - 23) | | +---------- day of month (1 - 31) | | | +------- month (1 - 12) | | | | +---- day of week (0 - 7) (Sunday=0 or 7) | | | | | * * * * *

Each of the patterns from the first five fields may be either * (an asterisk), which matches all legal values, or a list of elements separated by commas.

See http://en.wikipedia.org/wiki/Cron for more information.

Показать файл Открыть проект

Private Properties

Свойство Тип Описание

Открытые методы

Метод Описание
Equals ( object obj ) : bool

Determines whether the specified Schedule is equal to the current Schedule.

GetHashCode ( ) : int

Gets a hash code for the Schedule.

IsDue ( ) : bool

Checks whether the Schedule is due at the present system time.

Schedule ( ) : System

Initializes a new instance of the Schedule class.

Schedule ( string name ) : System

Initializes a new instance of the Schedule class.

Default Rule of '* * * * *' is used.

Schedule ( string name, string rule ) : System

Initializes a new instance of the Schedule class.

Schedule ( string name, string rule, string description ) : System

Initializes a new instance of the Schedule class.

Schedule ( string name, string rule, string description, bool useLocalTime ) : System

Initializes a new instance of the Schedule class.

ToString ( ) : string

Gets the string representation of Schedule.

Описание методов

Equals() публичный Метод

Determines whether the specified Schedule is equal to the current Schedule.
public Equals ( object obj ) : bool
obj object The to compare with the current .
Результат bool

GetHashCode() публичный Метод

Gets a hash code for the Schedule.
public GetHashCode ( ) : int
Результат int

IsDue() публичный Метод

Checks whether the Schedule is due at the present system time.
public IsDue ( ) : bool
Результат bool

Schedule() публичный Метод

Initializes a new instance of the Schedule class.
public Schedule ( ) : System
Результат System

Schedule() публичный Метод

Initializes a new instance of the Schedule class.
Default Rule of '* * * * *' is used.
public Schedule ( string name ) : System
name string Name of the schedule.
Результат System

Schedule() публичный Метод

Initializes a new instance of the Schedule class.
public Schedule ( string name, string rule ) : System
name string Name of the schedule.
rule string Rule formated in UNIX crontab syntax.
Результат System

Schedule() публичный Метод

Initializes a new instance of the Schedule class.
public Schedule ( string name, string rule, string description ) : System
name string Name of the schedule.
rule string Rule formated in UNIX crontab syntax.
description string Description of defined schedule.
Результат System

Schedule() публичный Метод

Initializes a new instance of the Schedule class.
public Schedule ( string name, string rule, string description, bool useLocalTime ) : System
name string Name of the schedule.
rule string Rule formated in UNIX crontab syntax.
description string Description of defined schedule.
useLocalTime bool Flag that determines whether to use local time for schedule.
Результат System

ToString() публичный Метод

Gets the string representation of Schedule.
public ToString ( ) : string
Результат string