Class: Azure::ServiceBus::SqlRuleAction
- Inherits:
-
Action
- Object
- RuleAspect
- Action
- Azure::ServiceBus::SqlRuleAction
- Defined in:
- lib/azure/service_bus/sql_rule_action.rb
Instance Attribute Summary collapse
-
#compatibility_level ⇒ Object
Returns the value of attribute compatibility_level.
-
#sql_expression ⇒ Object
Returns the value of attribute sql_expression.
Instance Method Summary collapse
-
#initialize(hash = nil) ⇒ SqlRuleAction
constructor
Public: Initialize the SQL Rule Action.
- #to_hash(hash = {}) ⇒ Object
Methods inherited from RuleAspect
Constructor Details
#initialize(hash = nil) ⇒ SqlRuleAction
Public: Initialize the SQL Rule Action.
Attributes
-
hash
- The resource options Hash
Options
Accepted key/value pairs in options parameter are:
-
:sql_expression
- The SQL expression. -
:compatibility_level
- The compatibility level.
33 34 35 36 37 38 |
# File 'lib/azure/service_bus/sql_rule_action.rb', line 33 def initialize(hash=nil) hash = {} unless hash @sql_expression = hash[:sql_expression] @compatibility_level = (hash[:compatibility_level] || 20).to_i super() end |
Instance Attribute Details
#compatibility_level ⇒ Object
Returns the value of attribute compatibility_level.
41 42 43 |
# File 'lib/azure/service_bus/sql_rule_action.rb', line 41 def compatibility_level @compatibility_level end |
#sql_expression ⇒ Object
Returns the value of attribute sql_expression.
40 41 42 |
# File 'lib/azure/service_bus/sql_rule_action.rb', line 40 def sql_expression @sql_expression end |
Instance Method Details
#to_hash(hash = {}) ⇒ Object
43 44 45 46 47 |
# File 'lib/azure/service_bus/sql_rule_action.rb', line 43 def to_hash(hash={}) hash[:sql_expression]=sql_expression if sql_expression hash[:compatibility_level]=compatibility_level.to_s if compatibility_level super(hash) end |