Class: Ruleby::Core::Rule
- Inherits:
-
Object
- Object
- Ruleby::Core::Rule
- Defined in:
- lib/core/engine.rb
Instance Attribute Summary collapse
-
#action ⇒ Object
readonly
Returns the value of attribute action.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#pattern ⇒ Object
Returns the value of attribute pattern.
-
#priority ⇒ Object
Returns the value of attribute priority.
Instance Method Summary collapse
-
#initialize(name, pattern = nil, action = nil, priority = 0) ⇒ Rule
constructor
A new instance of Rule.
Constructor Details
#initialize(name, pattern = nil, action = nil, priority = 0) ⇒ Rule
Returns a new instance of Rule.
97 98 99 100 101 102 |
# File 'lib/core/engine.rb', line 97 def initialize(name, pattern=nil, action=nil, priority=0) @name = name @pattern = pattern @action = action @priority = priority end |
Instance Attribute Details
#action ⇒ Object (readonly)
Returns the value of attribute action.
95 96 97 |
# File 'lib/core/engine.rb', line 95 def action @action end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
95 96 97 |
# File 'lib/core/engine.rb', line 95 def name @name end |
#pattern ⇒ Object
Returns the value of attribute pattern.
94 95 96 |
# File 'lib/core/engine.rb', line 94 def pattern @pattern end |
#priority ⇒ Object
Returns the value of attribute priority.
95 96 97 |
# File 'lib/core/engine.rb', line 95 def priority @priority end |