Class: Checkoff::SelectorClasses::Task::InSectionNamedPFunctionEvaluator
- Inherits:
-
FunctionEvaluator
- Object
- FunctionEvaluator
- FunctionEvaluator
- Checkoff::SelectorClasses::Task::InSectionNamedPFunctionEvaluator
- Defined in:
- lib/checkoff/internal/selector_classes/task.rb,
sig/checkoff.rbs
Overview
:in_section_named? function
Instance Attribute Summary
Attributes inherited from FunctionEvaluator
#custom_fields, #selector, #tasks, #timelines
Instance Method Summary collapse
-
#evaluate(task, section_name) ⇒ Boolean
sord warn - Asana::Resources::Task wasn't able to be resolved to a constant in this project @param
task. -
#evaluate_arg?(_index) ⇒ Boolean
@param
_index. - #matches? ⇒ Boolean
Methods inherited from FunctionEvaluator
Methods inherited from FunctionEvaluator
#debug, #error, #finer, #fn?, #info, #initialize, #log_level, #logger, #warn
Methods included from Logging
#debug, #error, #finer, #info, #log_level, #logger, #warn
Constructor Details
This class inherits a constructor from Checkoff::SelectorClasses::Task::FunctionEvaluator
Instance Method Details
#evaluate(task, section_name) ⇒ Boolean
sord warn - Asana::Resources::Task wasn't able to be resolved to a constant in this project
@param task
@param section_name
83 84 85 86 87 88 89 90 91 92 93 94 95 |
# File 'lib/checkoff/internal/selector_classes/task.rb', line 83 def evaluate(task, section_name) # @type [Hash{'unwrapped' => Hash}] task_data = tasks.task_to_h(task) # @type [Hash{'membership_by_section_name' => Hash}] # @sg-ignore Hash#fetch generic<X> leak on rbs >= 4.1.0, fix in progress upstream # https://github.com/castwide/solargraph/pull/1228 unwrapped = task_data.fetch('unwrapped') # @type [Array] # @sg-ignore Hash#fetch generic<X> leak on rbs >= 4.1.0, fix in progress upstream # https://github.com/castwide/solargraph/pull/1228 section_names = unwrapped.fetch('membership_by_section_name').keys section_names.any?(section_name) end |
#evaluate_arg?(_index) ⇒ Boolean
@param _index
76 77 78 |
# File 'lib/checkoff/internal/selector_classes/task.rb', line 76 def evaluate_arg?(_index) false end |
#matches? ⇒ Boolean
71 72 73 |
# File 'lib/checkoff/internal/selector_classes/task.rb', line 71 def matches? fn?(selector, :in_section_named?) end |