New to Telerik UI for ASP.NET MVC? Start a free 30-day trial

Represents declarative filtering.

Definition

Constructors

Initializes a new instance of the FilterDescriptor class.

C#
public FilterDescriptor()

Initializes a new instance of the FilterDescriptor class.

C#
public FilterDescriptor(string member, FilterOperator filterOperator, object filterValue)
Parameters:memberstring

The member.

filterOperatorFilterOperator

The filter operator.

filterValueobject

The filter value.

Properties

C#
public object ConvertedValue { get; }

Gets or sets the member name which will be used for filtering.

C#
public string Member { get; set; }

Gets or sets the type of the member that is used for filtering. Set this property if the member type cannot be resolved automatically. Such cases are: items with ICustomTypeDescriptor, XmlNode or DataRow. Changing this property did not raise

C#
public Type MemberType { get; set; }
Property Value:

The type of the member used for filtering.

Gets or sets the filter operator.

C#
public FilterOperator Operator { get; set; }

Gets or sets the target filter value.

C#
public object Value { get; set; }

Methods

Creates a predicate filter expression.

C#
protected override Expression CreateFilterExpression(ParameterExpression parameterExpression)
Parameters:parameterExpressionParameterExpression

The parameter expression, which will be used for filtering.

Returns:

Expression

A predicate filter expression.

Overrides: FilterDescriptorBase.CreateFilterExpression(ParameterExpression)

Determines whether the specified other descriptor is equal to the current one.

C#
public virtual bool Equals(FilterDescriptor other)
Parameters:otherFilterDescriptor

The other filter descriptor.

Returns:

bool

True if all members of the current descriptor are equal to the ones of other, otherwise false.

Determines whether the specified obj is equal to the current descriptor.

C#
public override bool Equals(object obj)
Parameters:objobjectReturns:

bool

Overrides: object.Equals(object)

Serves as a hash function for a particular type.

C#
public override int GetHashCode()
Returns:

int

A hash code for the current filter descriptor.

Overrides: object.GetHashCode()

C#
protected override void Serialize(IDictionary<string, object> json)
Parameters:jsonIDictionary<string, object>

Overrides: FilterDescriptorBase.Serialize(IDictionary<string, object>)