Class: SeisRuby::Data::Cmtsolution

Inherits:
SeisRuby::Data show all
Defined in:
lib/seis_ruby/data/cmtsolution.rb

Defined Under Namespace

Classes: Centroid, Hypocenter

Instance Attribute Summary collapse

Attributes inherited from SeisRuby::Data

#meta_data, #raw_data

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(raw_data, meta_data) ⇒ Cmtsolution

Returns a new instance of Cmtsolution.



12
13
14
15
16
# File 'lib/seis_ruby/data/cmtsolution.rb', line 12

def initialize(raw_data, )
  @raw_data = raw_data
  @meta_data = 
  parse!
end

Instance Attribute Details

#centroidObject

Returns the value of attribute centroid.



18
19
20
# File 'lib/seis_ruby/data/cmtsolution.rb', line 18

def centroid
  @centroid
end

#hypocenterObject

Returns the value of attribute hypocenter.



17
18
19
# File 'lib/seis_ruby/data/cmtsolution.rb', line 17

def hypocenter
  @hypocenter
end

Class Method Details

.load(raw_data, meta_data) ⇒ Object



8
9
10
# File 'lib/seis_ruby/data/cmtsolution.rb', line 8

def self.load(raw_data, )
  new(raw_data, )
end

.load_file(file) ⇒ Object



4
5
6
# File 'lib/seis_ruby/data/cmtsolution.rb', line 4

def self.load_file(file)
  load(File.read_uri(file), file: file)
end