Class: Lagoon::Analyzer::ControllerScopeCollector::Callback
- Inherits:
-
Data
- Object
- Data
- Lagoon::Analyzer::ControllerScopeCollector::Callback
- Defined in:
- lib/lagoon/analyzer/ast/controller_scope_collector.rb
Instance Attribute Summary collapse
-
#except_actions ⇒ Object
readonly
Returns the value of attribute except_actions.
-
#method_name ⇒ Object
readonly
Returns the value of attribute method_name.
-
#only_actions ⇒ Object
readonly
Returns the value of attribute only_actions.
Instance Method Summary collapse
Instance Attribute Details
#except_actions ⇒ Object (readonly)
Returns the value of attribute except_actions
6 7 8 |
# File 'lib/lagoon/analyzer/ast/controller_scope_collector.rb', line 6 def except_actions @except_actions end |
#method_name ⇒ Object (readonly)
Returns the value of attribute method_name
6 7 8 |
# File 'lib/lagoon/analyzer/ast/controller_scope_collector.rb', line 6 def method_name @method_name end |
#only_actions ⇒ Object (readonly)
Returns the value of attribute only_actions
6 7 8 |
# File 'lib/lagoon/analyzer/ast/controller_scope_collector.rb', line 6 def only_actions @only_actions end |
Instance Method Details
#applies_to?(action) ⇒ Boolean
7 8 9 10 11 12 |
# File 'lib/lagoon/analyzer/ast/controller_scope_collector.rb', line 7 def applies_to?(action) return false if except_actions.include?(action) return true if only_actions.empty? only_actions.include?(action) end |