Class: PokeApi::Common::Description

Inherits:
Object
  • Object
show all
Defined in:
lib/poke_api/common/description.rb

Overview

Description object handling lists of descriptions and languages

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ Description

Returns a new instance of Description.



8
9
10
11
# File 'lib/poke_api/common/description.rb', line 8

def initialize(data)
  @description = data[:description]
  @language    = Utility::Language.new(data[:language])
end

Instance Attribute Details

#descriptionObject (readonly)

Returns the value of attribute description.



5
6
7
# File 'lib/poke_api/common/description.rb', line 5

def description
  @description
end

#languageObject (readonly)

Returns the value of attribute language.



5
6
7
# File 'lib/poke_api/common/description.rb', line 5

def language
  @language
end