C# Class CronExpressionDescriptor.ExpressionDescriptor

Converts a Cron Expression into a human readable string
Afficher le fichier Open project: bradyholt/cron-expression-descriptor Class Usage Examples

Méthodes publiques

Méthode Description
ExpressionDescriptor ( string expression ) : System

Initializes a new instance of the ExpressionDescriptor class

ExpressionDescriptor ( string expression, Options options ) : System

Initializes a new instance of the ExpressionDescriptor class

GetDescription ( DescriptionTypeEnum type ) : string

Generates a human readable string for the Cron Expression

GetDescription ( string expression ) : string

Generates a human readable string for the Cron Expression

GetDescription ( string expression, Options options ) : string

Generates a human readable string for the Cron Expression

Méthodes protégées

Méthode Description
FormatTime ( string hourExpression, string minuteExpression ) : string

Given time parts, will contruct a formatted time description

FormatTime ( string hourExpression, string minuteExpression, string secondExpression ) : string

Given time parts, will contruct a formatted time description

GenerateBetweenSegmentDescription ( string betweenExpression, string>.Func getBetweenDescriptionFormat, string>.Func getSingleItemDescription ) : string

Generates the between segment description

GetDayOfMonthDescription ( ) : string

Generates a description for only the DAYOFMONTH portion of the expression

GetDayOfWeekDescription ( ) : string

Generates a description for only the DAYOFWEEK portion of the expression

GetFullDescription ( ) : string

Generates the FULL description

GetHoursDescription ( ) : string

Generates a description for only the HOUR portion of the expression

GetMinutesDescription ( ) : string

Generates a description for only the MINUTE portion of the expression

GetMonthDescription ( ) : string

Generates a description for only the MONTH portion of the expression

GetSecondsDescription ( ) : string

Generates a description for only the SECONDS portion of the expression

GetSegmentDescription ( string expression, string allDescription, string>.Func getSingleItemDescription, string>.Func getIntervalDescriptionFormat, string>.Func getBetweenDescriptionFormat, string>.Func getDescriptionFormat ) : string

Generates the segment description

GetTimeOfDayDescription ( ) : string

Generates a description for only the TIMEOFDAY portion of the expression

TransformCase ( string description, CasingTypeEnum caseType ) : string

Transforms the case of the expression description, based on options

TransformVerbosity ( string description, bool useVerboseFormat ) : string

Transforms the verbosity of the expression description by stripping verbosity from original description

Private Methods

Méthode Description
GetYearDescription ( ) : string

Generates a description for only the YEAR portion of the expression

Method Details

ExpressionDescriptor() public méthode

Initializes a new instance of the ExpressionDescriptor class
public ExpressionDescriptor ( string expression ) : System
expression string The cron expression string
Résultat System

ExpressionDescriptor() public méthode

Initializes a new instance of the ExpressionDescriptor class
public ExpressionDescriptor ( string expression, Options options ) : System
expression string The cron expression string
options Options Options to control the output description
Résultat System

FormatTime() protected méthode

Given time parts, will contruct a formatted time description
protected FormatTime ( string hourExpression, string minuteExpression ) : string
hourExpression string Hours part
minuteExpression string Minutes part
Résultat string

FormatTime() protected méthode

Given time parts, will contruct a formatted time description
protected FormatTime ( string hourExpression, string minuteExpression, string secondExpression ) : string
hourExpression string Hours part
minuteExpression string Minutes part
secondExpression string Seconds part
Résultat string

GenerateBetweenSegmentDescription() protected méthode

Generates the between segment description
protected GenerateBetweenSegmentDescription ( string betweenExpression, string>.Func getBetweenDescriptionFormat, string>.Func getSingleItemDescription ) : string
betweenExpression string
getBetweenDescriptionFormat string>.Func
getSingleItemDescription string>.Func
Résultat string

GetDayOfMonthDescription() protected méthode

Generates a description for only the DAYOFMONTH portion of the expression
protected GetDayOfMonthDescription ( ) : string
Résultat string

GetDayOfWeekDescription() protected méthode

Generates a description for only the DAYOFWEEK portion of the expression
protected GetDayOfWeekDescription ( ) : string
Résultat string

GetDescription() public méthode

Generates a human readable string for the Cron Expression
public GetDescription ( DescriptionTypeEnum type ) : string
type DescriptionTypeEnum Which part(s) of the expression to describe
Résultat string

GetDescription() public static méthode

Generates a human readable string for the Cron Expression
public static GetDescription ( string expression ) : string
expression string The cron expression string
Résultat string

GetDescription() public static méthode

Generates a human readable string for the Cron Expression
public static GetDescription ( string expression, Options options ) : string
expression string The cron expression string
options Options Options to control the output description
Résultat string

GetFullDescription() protected méthode

Generates the FULL description
protected GetFullDescription ( ) : string
Résultat string

GetHoursDescription() protected méthode

Generates a description for only the HOUR portion of the expression
protected GetHoursDescription ( ) : string
Résultat string

GetMinutesDescription() protected méthode

Generates a description for only the MINUTE portion of the expression
protected GetMinutesDescription ( ) : string
Résultat string

GetMonthDescription() protected méthode

Generates a description for only the MONTH portion of the expression
protected GetMonthDescription ( ) : string
Résultat string

GetSecondsDescription() protected méthode

Generates a description for only the SECONDS portion of the expression
protected GetSecondsDescription ( ) : string
Résultat string

GetSegmentDescription() protected méthode

Generates the segment description
protected GetSegmentDescription ( string expression, string allDescription, string>.Func getSingleItemDescription, string>.Func getIntervalDescriptionFormat, string>.Func getBetweenDescriptionFormat, string>.Func getDescriptionFormat ) : string
expression string
allDescription string
getSingleItemDescription string>.Func
getIntervalDescriptionFormat string>.Func
getBetweenDescriptionFormat string>.Func
getDescriptionFormat string>.Func
Résultat string

GetTimeOfDayDescription() protected méthode

Generates a description for only the TIMEOFDAY portion of the expression
protected GetTimeOfDayDescription ( ) : string
Résultat string

TransformCase() protected méthode

Transforms the case of the expression description, based on options
protected TransformCase ( string description, CasingTypeEnum caseType ) : string
description string The description to transform
caseType CasingTypeEnum The casing type that controls the output casing
Résultat string

TransformVerbosity() protected méthode

Transforms the verbosity of the expression description by stripping verbosity from original description
protected TransformVerbosity ( string description, bool useVerboseFormat ) : string
description string The description to transform
useVerboseFormat bool
Résultat string