RuleAction RuleAction Class

Represents the filter actions which are allowed for the transformation of a message that have been matched by a filter expression.

Syntax

Declaration

[DataContract(Name = "RuleAction", Namespace = "http://schemas.microsoft.com/netservices/2010/10/servicebus/connect")]
[KnownType(typeof (EmptyRuleAction))]
[KnownType(typeof (SqlRuleAction))]
[KnownType(typeof (CompositeAction))]
[KnownType(typeof (RuleCreationAction))]
[KnownType(typeof (DateTimeOffset))]
public abstract class RuleAction : IExtensibleDataObject<DataContract(Name:="RuleAction", Namespace:="http://schemas.microsoft.com/netservices/2010/10/servicebus/connect")>
<KnownType(GetType(EmptyRuleAction))>
<KnownType(GetType(SqlRuleAction))>
<KnownType(GetType(CompositeAction))>
<KnownType(GetType(RuleCreationAction))>
<KnownType(GetType(DateTimeOffset))>
Public MustInherit Class RuleAction
    Implements IExtensibleDataObject

Inheritance Hierarchy

Remarks

Filter actions allow for the transformation of a message that have been matched by a filter expression. The typical use case for filter acions is to append or update the properties that are attached to a message, for example assigning a group ID based on the correlation ID of a message.

Properties summary

Gets a value that indicates whether the rule action requires preprocessing.

Methods summary

Executes the filter action on the supplied BrokeredMessage.

Preprocesses the RuleAction object.

Validates the rule action against the grammar.

Explicit Interface Implementations summary

Properties

  • RequiresPreprocessing
    RequiresPreprocessing

    Gets a value that indicates whether the rule action requires preprocessing.

    public abstract bool RequiresPreprocessing { get; }Public MustOverride ReadOnly Property RequiresPreprocessing As Boolean

    Property Value

    • true if the rule action requires preprocessing; otherwise, false.

Methods

  • Execute(BrokeredMessage)
    Execute(BrokeredMessage)

    Executes the filter action on the supplied BrokeredMessage.

    public abstract BrokeredMessage Execute(BrokeredMessage message)Public MustOverride Function Execute(message As BrokeredMessage) As BrokeredMessage

    Parameters

    Returns

    Remarks

    Concrete implementation of this class is free to throw InvalidOperationException is this requires preprocessing.

  • Preprocess()
    Preprocess()

    Preprocesses the RuleAction object.

    public abstract RuleAction Preprocess()Public MustOverride Function Preprocess As RuleAction

    Returns

    Remarks

    Concrete implementation of this class is free to throw InvalidOperationException is this requires preprocessing.

  • Validate()
    Validate()

    Validates the rule action against the grammar.

    public abstract void Validate()Public MustOverride Sub Validate

    Remarks

    Concrete implementation of this class is free to throw InvalidOperationException is this requires preprocessing.

Explicit Interface Implementations

  • IExtensibleDataObject.ExtensionData
    System.Runtime.Serialization.IExtensibleDataObject.ExtensionData
    ExtensionDataObject IExtensibleDataObject.ExtensionData { get; set; }ReadOnly WriteOnly Property System.Runtime.Serialization.IExtensibleDataObject.ExtensionData As ExtensionDataObject Implements IExtensibleDataObject.ExtensionData

    Returns

Attributes

System.Runtime.Serialization.DataContractAttribute
System.Runtime.Serialization.KnownTypeAttribute
System.Runtime.Serialization.KnownTypeAttribute

Details

Namespace

Microsoft.ServiceBus.Messaging

Assembly

Microsoft.ServiceBus.dll

See Also