Class: Pod::Component
- Inherits:
-
Object
- Object
- Pod::Component
- Defined in:
- lib/cocoapods-vemars/command/component.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#subspecs ⇒ Object
readonly
Returns the value of attribute subspecs.
-
#version ⇒ Object
readonly
Returns the value of attribute version.
Instance Method Summary collapse
-
#initialize(json) ⇒ Component
constructor
def initialize(name, version, subspecs = []) @name = name @version = version @subspecs = subspecs end.
- #to_s ⇒ Object
Constructor Details
#initialize(json) ⇒ Component
def initialize(name, version, subspecs = [])
@name = name
@version = version
@subspecs = subspecs
end
13 14 15 16 17 |
# File 'lib/cocoapods-vemars/command/component.rb', line 13 def initialize(json) @name = json["name"] @version = json["version"] @subspecs = json["subspecs"] end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
3 4 5 |
# File 'lib/cocoapods-vemars/command/component.rb', line 3 def name @name end |
#subspecs ⇒ Object (readonly)
Returns the value of attribute subspecs.
5 6 7 |
# File 'lib/cocoapods-vemars/command/component.rb', line 5 def subspecs @subspecs end |
#version ⇒ Object (readonly)
Returns the value of attribute version.
4 5 6 |
# File 'lib/cocoapods-vemars/command/component.rb', line 4 def version @version end |
Instance Method Details
#to_s ⇒ Object
19 20 21 22 23 24 25 |
# File 'lib/cocoapods-vemars/command/component.rb', line 19 def to_s puts "===================================" puts "name: #{@name}\nversion: #{@version}\n" if !@subspecs.nil? && @subspecs.length > 0 puts "subspecs: #{@subspecs}\n" end end |