Class: BroadcastEvent::MetadataHelpers::SimpleMetadataFinder
- Inherits:
-
Object
- Object
- BroadcastEvent::MetadataHelpers::SimpleMetadataFinder
- Defined in:
- app/models/broadcast_event/metadata_helpers.rb
Overview
rubocop:todo Style/Documentation
Instance Attribute Summary collapse
-
#method ⇒ Object
readonly
Returns the value of attribute method.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #for(seed, _event) ⇒ Object
-
#initialize(name, method) ⇒ SimpleMetadataFinder
constructor
A new instance of SimpleMetadataFinder.
Constructor Details
#initialize(name, method) ⇒ SimpleMetadataFinder
Returns a new instance of SimpleMetadataFinder.
5 6 7 8 |
# File 'app/models/broadcast_event/metadata_helpers.rb', line 5 def initialize(name, method) @name = name.to_s @method = method end |
Instance Attribute Details
#method ⇒ Object (readonly)
Returns the value of attribute method
3 4 5 |
# File 'app/models/broadcast_event/metadata_helpers.rb', line 3 def method @method end |
#name ⇒ Object (readonly)
Returns the value of attribute name
3 4 5 |
# File 'app/models/broadcast_event/metadata_helpers.rb', line 3 def name @name end |
Instance Method Details
#for(seed, _event) ⇒ Object
10 11 12 |
# File 'app/models/broadcast_event/metadata_helpers.rb', line 10 def for(seed, _event) [name, seed.send(method)] end |