Class: PodspecEditor::Spec
- Inherits:
-
Object
- Object
- PodspecEditor::Spec
- Defined in:
- lib/podspec/editor.rb
Instance Attribute Summary collapse
-
#inner_spec ⇒ Object
Returns the value of attribute inner_spec.
Instance Method Summary collapse
-
#initialize(json_content) ⇒ Spec
constructor
A new instance of Spec.
-
#method_missing(method, *args, &block) ⇒ Object
read.
Constructor Details
#initialize(json_content) ⇒ Spec
Returns a new instance of Spec.
26 27 28 |
# File 'lib/podspec/editor.rb', line 26 def initialize(json_content) @inner_spec = JSON.parse(json_content, object_class: OpenStruct) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object
read
31 32 33 |
# File 'lib/podspec/editor.rb', line 31 def method_missing(method, *args, &block) inner_spec.send(method, *args, &block) end |
Instance Attribute Details
#inner_spec ⇒ Object
Returns the value of attribute inner_spec.
24 25 26 |
# File 'lib/podspec/editor.rb', line 24 def inner_spec @inner_spec end |