Class: Rome2rio::Aircraft

Inherits:
Object
  • Object
show all
Defined in:
lib/rome2rio/response/aircraft.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ Aircraft

Returns a new instance of Aircraft.



4
5
6
7
8
# File 'lib/rome2rio/response/aircraft.rb', line 4

def initialize(json)
  @code = json["code"]
  @manufacturer = json["manufacturer"]
  @model = json["model"]
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



3
4
5
# File 'lib/rome2rio/response/aircraft.rb', line 3

def code
  @code
end

#manufacturerObject (readonly)

Returns the value of attribute manufacturer.



3
4
5
# File 'lib/rome2rio/response/aircraft.rb', line 3

def manufacturer
  @manufacturer
end

#modelObject (readonly)

Returns the value of attribute model.



3
4
5
# File 'lib/rome2rio/response/aircraft.rb', line 3

def model
  @model
end