C# Class Stumps.Rules.BodyLengthRule

A class representing a Stump rule that evaluates the length of the body of an HTTP request.
Inheritance: IStumpRule
显示文件 Open project: Cayan-LLC/stumps Class Usage Examples

Public Methods

Method Description
BodyLengthRule ( ) : System

Initializes a new instance of the T:Stumps.Rules.BodyLengthRule class.

BodyLengthRule ( int minimumBodyLength, int maximumBodyLength ) : System

Initializes a new instance of the T:Stumps.Rules.BodyLengthRule class.

GetRuleSettings ( ) : IEnumerable

Gets an enumerable list of T:Stumps.RuleSetting objects used to represent the current instance.

InitializeFromSettings ( IEnumerable settings ) : void

Initializes a rule from an enumerable list of T:Stumps.RuleSetting objects.

IsMatch ( IStumpsHttpRequest request ) : bool

Determines whether the specified request matches the rule.

Method Details

BodyLengthRule() public method

Initializes a new instance of the T:Stumps.Rules.BodyLengthRule class.
public BodyLengthRule ( ) : System
return System

BodyLengthRule() public method

Initializes a new instance of the T:Stumps.Rules.BodyLengthRule class.
public BodyLengthRule ( int minimumBodyLength, int maximumBodyLength ) : System
minimumBodyLength int The minimum length of the body.
maximumBodyLength int The maximum length of the body.
return System

GetRuleSettings() public method

Gets an enumerable list of T:Stumps.RuleSetting objects used to represent the current instance.
public GetRuleSettings ( ) : IEnumerable
return IEnumerable

InitializeFromSettings() public method

Initializes a rule from an enumerable list of T:Stumps.RuleSetting objects.
public InitializeFromSettings ( IEnumerable settings ) : void
settings IEnumerable The enumerable list of objects.
return void

IsMatch() public method

Determines whether the specified request matches the rule.
public IsMatch ( IStumpsHttpRequest request ) : bool
request IStumpsHttpRequest The to evaluate.
return bool