Class: Higan::Target
- Inherits:
-
Object
- Object
- Higan::Target
- Defined in:
- lib/higan/target.rb
Instance Attribute Summary collapse
-
#klass ⇒ Object
Returns the value of attribute klass.
-
#path ⇒ Object
Returns the value of attribute path.
-
#renderer ⇒ Object
Returns the value of attribute renderer.
-
#scope ⇒ Object
Returns the value of attribute scope.
-
#template ⇒ Object
Returns the value of attribute template.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
- #element_list ⇒ Object
-
#initialize(**params) ⇒ Target
constructor
A new instance of Target.
- #key(id) ⇒ Object
Constructor Details
#initialize(**params) ⇒ Target
Returns a new instance of Target.
5 6 7 8 9 |
# File 'lib/higan/target.rb', line 5 def initialize(**params) params.each_pair do |k, v| self.send("#{k}=", v) end end |
Instance Attribute Details
#klass ⇒ Object
Returns the value of attribute klass.
3 4 5 |
# File 'lib/higan/target.rb', line 3 def klass @klass end |
#path ⇒ Object
Returns the value of attribute path.
3 4 5 |
# File 'lib/higan/target.rb', line 3 def path @path end |
#renderer ⇒ Object
Returns the value of attribute renderer.
3 4 5 |
# File 'lib/higan/target.rb', line 3 def renderer @renderer end |
#scope ⇒ Object
Returns the value of attribute scope.
3 4 5 |
# File 'lib/higan/target.rb', line 3 def scope @scope end |
#template ⇒ Object
Returns the value of attribute template.
3 4 5 |
# File 'lib/higan/target.rb', line 3 def template @template end |
#value ⇒ Object
Returns the value of attribute value.
3 4 5 |
# File 'lib/higan/target.rb', line 3 def value @value end |
Instance Method Details
#element_list ⇒ Object
11 12 13 |
# File 'lib/higan/target.rb', line 11 def element_list klass.send(scope) end |
#key(id) ⇒ Object
15 16 17 |
# File 'lib/higan/target.rb', line 15 def key(id) [klass, id].join('::') end |