Class: Azure::ServiceBus::SqlFilter
- Inherits:
-
Filter
- Object
- RuleAspect
- Filter
- Azure::ServiceBus::SqlFilter
- Defined in:
- lib/azure/service_bus/sql_filter.rb
Direct Known Subclasses
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) ⇒ SqlFilter
constructor
Public: Initialize the SQL Rule Filter.
- #to_hash(hash = {}) ⇒ Object
Methods inherited from RuleAspect
Constructor Details
#initialize(hash = nil) ⇒ SqlFilter
Public: Initialize the SQL Rule Filter.
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_filter.rb', line 33 def initialize(hash=nil) hash = {} unless hash @sql_expression = hash[:sql_expression] if hash[:sql_expression] @compatibility_level = (hash[:compatibility_level] || 20).to_i if hash[:compatibility_level] super() end |
Instance Attribute Details
#compatibility_level ⇒ Object
Returns the value of attribute compatibility_level.
41 42 43 |
# File 'lib/azure/service_bus/sql_filter.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_filter.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_filter.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 |