class Azure::ServiceBus::Rule
Attributes
subscription[RW]
topic[RW]
Public Class Methods
new(name, options = {})
click to toggle source
Public: Initialize the rule.
Attributes¶ ↑
-
name
- AString
with the name of the rule. -
options
- The resource options Hash
Options¶ ↑
Accepted key/value pairs in options parameter are:
Calls superclass method
Azure::ServiceBus::Resource::new
# File lib/azure/service_bus/rule.rb, line 46 def initialize(name, options = {}) normalized_options = {} normalized_options["Filter"] = options[:filter] if options.has_key?(:filter) normalized_options["Action"] = options[:action] if options.has_key?(:action) super(name, normalized_options) end
Public Instance Methods
action()
click to toggle source
Action: String
The Action
property references an instance of FilterAction. The following type of FilterAction are provided. Default is an instance of EmptyRuleAction
.
SqlFilterAction - A type of FilterAction that is represented by SQL expression. For detailed information about SqlFilterAction syntax, see SqlRuleAction.SqlExpression Property. EmptyRuleAction - A type of FilterAction that represents an empty action.
# File lib/azure/service_bus/rule.rb, line 82 def action RuleAspect.from_hash(description['Action']) end
action=(val)
click to toggle source
# File lib/azure/service_bus/rule.rb, line 86 def action=(val) description['Action'] = val.to_hash end
filter()
click to toggle source
Filter: SqlFilter
, TrueFilter
/FalseFiilter, CorrelationFilter
The Filter
property references an instance of Filter
that is evaluated against a message. The following types of filters are provided:
SqlFilter - A type of Filter that is represented by SQL expression. For detailed information about SqlFilter syntax, see SqlFilter.SqlExpression Property. TrueFilter/FalseFiilter - A handy shortcut for always returning true or false. They are a type of SqlFilter. CorrelationFilter: A type of Filter that matches CorrelationId property of BrokeredMessage.
# File lib/azure/service_bus/rule.rb, line 65 def filter RuleAspect.from_hash(description['Filter']) end
filter=(val)
click to toggle source
# File lib/azure/service_bus/rule.rb, line 69 def filter=(val) description['Filter'] = val.to_hash end
ordered_props()
click to toggle source
# File lib/azure/service_bus/rule.rb, line 90 def ordered_props [ 'Filter', 'Action' ] end