Class: Sistrix::Keyword::Domain::Seo::Record

Inherits:
Object
  • Object
show all
Includes:
Record
Defined in:
lib/sistrix/keyword/domain/seo.rb

Instance Method Summary collapse

Methods included from Record

#keys, #method_missing

Constructor Details

#initialize(xml_node) ⇒ Record

Returns a new instance of Record.



49
50
51
52
53
54
55
56
57
# File 'lib/sistrix/keyword/domain/seo.rb', line 49

def initialize(xml_node)
  @data = {}

  @data[:position] = xml_node['position'].to_s.strip.to_i
  @data[:kw] = xml_node['kw'].to_s.strip
  @data[:competition] = xml_node['competition'].to_s.strip.to_i
  @data[:traffic] = xml_node['traffic'].to_s.strip.to_i
  @data[:url] = xml_node['url'].to_s.strip
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Sistrix::Record