Class: KanjiMaster::Prefecture

Inherits:
Object
  • Object
show all
Defined in:
lib/kanji_master/prefecture.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(prefecture) ⇒ Prefecture

Returns a new instance of Prefecture.



13
14
15
16
17
18
19
# File 'lib/kanji_master/prefecture.rb', line 13

def initialize(prefecture)
  @name     = prefecture[:name]
  @romaji   = prefecture[:romaji]
  @hiragana = prefecture[:hiragana]
  @katakana = prefecture[:katakana]
  @area     = prefecture[:area]
end

Instance Attribute Details

#areaObject

Returns the value of attribute area.



11
12
13
# File 'lib/kanji_master/prefecture.rb', line 11

def area
  @area
end

#hiraganaObject

Returns the value of attribute hiragana.



11
12
13
# File 'lib/kanji_master/prefecture.rb', line 11

def hiragana
  @hiragana
end

#katakanaObject

Returns the value of attribute katakana.



11
12
13
# File 'lib/kanji_master/prefecture.rb', line 11

def katakana
  @katakana
end

#nameObject

Returns the value of attribute name.



11
12
13
# File 'lib/kanji_master/prefecture.rb', line 11

def name
  @name
end

#romajiObject

Returns the value of attribute romaji.



11
12
13
# File 'lib/kanji_master/prefecture.rb', line 11

def romaji
  @romaji
end

Class Method Details

.dataObject



8
9
10
# File 'lib/kanji_master/prefecture.rb', line 8

def self.data
  @data
end