Table of Contents

Class SqlFilter

Namespace
Microsoft.ServiceBus.Messaging
Assembly
Microsoft.ServiceBus.dll

Represents a filter which is a composition of an expression and an action that is executed in the pub/sub pipeline.

[KnownType(typeof(FalseFilter))]
[KnownType(typeof(TrueFilter))]
[KnownType(typeof(DateTimeOffset))]
[DataContract(Name = "SqlFilter", Namespace = "http://schemas.microsoft.com/netservices/2010/10/servicebus/connect")]
public class SqlFilter : Filter, IExtensibleDataObject
Inheritance
SqlFilter
Implements
IExtensibleDataObject
Derived
Inherited Members

Constructors

SqlFilter(string)

Initializes a new instance of the SqlFilter class using the specified SQL expression.

public SqlFilter(string sqlExpression)

Parameters

sqlExpression string

The SQL expression.

Properties

CompatibilityLevel

This property is reserved for future use. An integer value showing the compatibility level, currently hard-coded to 20.

[DataMember(Name = "CompatibilityLevel", Order = 65538, EmitDefaultValue = false, IsRequired = false)]
public int CompatibilityLevel { get; }

Property Value

int

The compatibility level.

Parameters

Sets the value of a filter expression.

public IDictionary<string, object> Parameters { get; }

Property Value

IDictionary<string, object>

The value of a filter expression.

RequiresPreprocessing

Gets a value indicating whether the SQL filter expression requires preprocessing.

public override bool RequiresPreprocessing { get; }

Property Value

bool

true if the SQL filter expression requires preprocessing; otherwise, false. Currently always returns true.

SqlExpression

Gets the SQL expression.

[DataMember(Name = "SqlExpression", Order = 65537, EmitDefaultValue = false, IsRequired = false)]
public string SqlExpression { get; }

Property Value

string

The SQL expression.

Methods

Match(BrokeredMessage)

Specifies whether a message matches against the current SQL expression.

public override bool Match(BrokeredMessage message)

Parameters

message BrokeredMessage

The BrokeredMessage.

Returns

bool

truea message matches against the current SQL expression; otherwise, false.

Preprocess()

Gets the preprocessed filter expression.

public override Filter Preprocess()

Returns

Filter

The preprocessed filter expression.

ToString()

Returns a string representation of SqlFilter.

public override string ToString()

Returns

string

The string representation of SqlFilter.

Validate()

Validates the SQL expression.

public override void Validate()