Class: Everypolitician::Popolo::Area

Inherits:
Entity
  • Object
show all
Defined in:
lib/everypolitician/popolo/area.rb

Instance Attribute Summary

Attributes inherited from Entity

#document, #popolo

Instance Method Summary collapse

Methods inherited from Entity

#==, #[], classification, #id, #identifier, inherited, #initialize, #key?, subclasses, #wikidata

Constructor Details

This class inherits a constructor from Everypolitician::Popolo::Entity

Instance Method Details

#identifiersObject


9
10
11
# File 'lib/everypolitician/popolo/area.rb', line 9

def identifiers
  document.fetch(:identifiers, [])
end

#nameObject


13
14
15
# File 'lib/everypolitician/popolo/area.rb', line 13

def name
  document.fetch(:name, nil)
end

#other_namesObject


17
18
19
# File 'lib/everypolitician/popolo/area.rb', line 17

def other_names
  document.fetch(:other_names, [])
end

#typeObject


21
22
23
# File 'lib/everypolitician/popolo/area.rb', line 21

def type
  document.fetch(:type, nil)
end