Class: IngvQuake::ShakeMap

Inherits:
Object
  • Object
show all
Defined in:
lib/ingv_quake/models/shake_map.rb

Overview

The ShakeMap class contains the map urls related to the Event.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ ShakeMap

Returns a new instance of ShakeMap.



12
13
14
15
16
# File 'lib/ingv_quake/models/shake_map.rb', line 12

def initialize(data)
  @intensity_map = data.fetch('intensity_map', nil)
  @pga_map = data.fetch('pga_map', nil)
  @pgv_map = data.fetch('pgv_map', nil)
end

Instance Attribute Details

#intensity_mapString (readonly)

Intensity map of the Event.

Returns:

  • (String)

    the current value of intensity_map



9
10
11
# File 'lib/ingv_quake/models/shake_map.rb', line 9

def intensity_map
  @intensity_map
end

#pga_mapString (readonly)

PGA map of Event.

Returns:

  • (String)

    the current value of pga_map



9
10
11
# File 'lib/ingv_quake/models/shake_map.rb', line 9

def pga_map
  @pga_map
end

#pgv_mapString (readonly)

PGV map of Event.

Returns:

  • (String)

    the current value of pgv_map



9
10
11
# File 'lib/ingv_quake/models/shake_map.rb', line 9

def pgv_map
  @pgv_map
end