Class
Filter

Represents the mechanism to filter objects.

Definition

Namespace:ArtOfTest.WebAii.Design.Execution

Assembly:ArtOfTest.WebAii.Design.dll

Syntax:

cs-api-definition
public class Filter

Inheritance: objectFilter

Constructors

Filter()

Declaration

cs-api-definition
public Filter()

Filter(string, object, int)

Declaration

cs-api-definition
public Filter(string key, object comparison, int value)

Parameters

key

string

comparison

object

value

int

Filter(string, object, string)

Declaration

cs-api-definition
public Filter(string key, object comparison, string value)

Parameters

key

string

comparison

object

value

string

Filter(string, string)

Declaration

cs-api-definition
public Filter(string key, string value)

Parameters

key

string

value

string

Properties

AcceptAll

Get whether the filter operates over all the tests in the project.

Declaration

cs-api-definition
public bool AcceptAll { get; }

Property Value

bool

Comparisons

Gets the list of the filter comparisons.

Declaration

cs-api-definition
public List<object> Comparisons { get; }

Property Value

List<object>

Keys

Gets the list of the filter keys.

Declaration

cs-api-definition
public List<string> Keys { get; }

Property Value

List<string>

Values

Gets the list of the filter values.

Declaration

cs-api-definition
public List<string> Values { get; }

Property Value

List<string>

Methods

AcceptAllTests()

Tells the filter to operate over all the tests in the project.

Declaration

cs-api-definition
public void AcceptAllTests()

AddClause(string, int)

Adds an equality clause for integer property value.

Declaration

cs-api-definition
public void AddClause(string key, int value)

Parameters

key

string

The key to search by.

value

int

The value corresponding to that key.

AddClause(string, object, int)

Adds a clause to the filtering criteria for an integer property value.

Declaration

cs-api-definition
public void AddClause(string key, object comparison, int value)

Parameters

key

string

The key to search by.

comparison

object

The filtering comparison.

value

int

The value corresponding to that key and comparison.

AddClause(string, object, string)

Adds a clause to the filtering criteria.

Declaration

cs-api-definition
public void AddClause(string key, object comparison, string value)

Parameters

key

string

The key to search by.

comparison

object

The filtering comparison.

value

string

The value corresponding to that key and comparison.

AddClause(string, string)

Adds an equality clause.

Declaration

cs-api-definition
public void AddClause(string key, string value)

Parameters

key

string

The key to search by.

value

string

The value corresponding to that key.

Clear()

Removes all items from the filter.

Declaration

cs-api-definition
public void Clear()

Clone()

Clones this instance.

Declaration

cs-api-definition
public Filter Clone()

Returns

Filter

GetFilterPropertyNames(Type)

Get the list of all target properties we can filter against.

Declaration

cs-api-definition
public static List<string> GetFilterPropertyNames(Type targetType)

Parameters

targetType

Type

Returns

List<string>

The list of all target properties we can filter against.

Match(object)

Gets whether the given test matches the current filtering criteria.

Declaration

cs-api-definition
public bool Match(object target)

Parameters

target

object

Returns

bool

Whether the given test matches the current filtering criteria.

RemoveClauseAt(int)

Removes the filter clause by the specified index.

Declaration

cs-api-definition
public void RemoveClauseAt(int index)

Parameters

index

int

The index of the clause.