C# Class Te.StahpIt.Filtering.FilteringCategory

The FilteringCategory class represents a category that includes a source of filtering rules, which is supplied to the filtering Engine. FilteringCategory objects are, once loaded, given over to the user to enable and disable.
Inheritance: IDisposable
Show file Open project: TechnikEmpire/StahpIt-WPF Class Usage Examples

Private Properties

Property Type Description
FilteringCategory ByteSizeLib
IsListExpired bool

Public Methods

Method Description
Dispose ( ) : void
FilteringCategory ( Engine engine ) : ByteSizeLib

Constructs a new filtering category. All members must be manually set, barring the ID. This is automatically generated within the constructor.

UpdateAndLoad ( ) : void

Updates, if necessary, the rule list and loads it into the Engine for use.

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Private Methods

Method Description
FilteringCategory ( ) : ByteSizeLib
IsListExpired ( ) : bool

Checks if the current list is expired.

Method Details

Dispose() public method

public Dispose ( ) : void
return void

Dispose() protected method

protected Dispose ( bool disposing ) : void
disposing bool
return void

FilteringCategory() public method

Constructs a new filtering category. All members must be manually set, barring the ID. This is automatically generated within the constructor.
/// The maximum number of categories is equal to the numeric limits of an 8 bit integer. /// Category ID are automatically generated from a static, Interlocked controlled count, then /// the result of the interlocked incremement is tested against this numeric limit. In other /// words, if more categories than this limit permits are constructed, this constructor will /// throw. /// /// In the event that the supplied Engine reference is null, will throw ArgumentException. ///
public FilteringCategory ( Engine engine ) : ByteSizeLib
engine Engine
return ByteSizeLib

UpdateAndLoad() public method

Updates, if necessary, the rule list and loads it into the Engine for use.
/// If updating, while attempting to download the list source, this exception may be thrown /// by the WebClient. This exception is not handled internally in order to allow users of the /// model to handle them. This exception will also be manually thrown if no file is present /// after the download. /// /// If updating, while attempting to download the list source, this exception may be thrown /// by the WebClient. This exception is not handled internally in order to allow users of the /// model to handle them. This exception may also be thrown if the file downloaded is larger /// than a hard-coded accepted memory limit. /// /// If updating, while attempting to parse the date, this exception may be thrown. This /// exception is not handled internally in order to allow users of the model to handle them. /// /// If updating, while attempting to parse the date, this exception may be thrown. This /// exception is not handled internally in order to allow users of the model to handle them. ///
public UpdateAndLoad ( ) : void
return void