Class: SEO::Position

Inherits:
Object
  • Object
show all
Defined in:
lib/seo/position.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#domainObject

Returns the value of attribute domain.



4
5
6
# File 'lib/seo/position.rb', line 4

def domain
  @domain
end

#keywordsObject

Returns the value of attribute keywords.



4
5
6
# File 'lib/seo/position.rb', line 4

def keywords
  @keywords
end

Class Method Details

.get(domain, keywords) ⇒ Object



11
12
13
14
15
16
# File 'lib/seo/position.rb', line 11

def self.get(domain, keywords)
  mechanize = Mechanize.new
  page = mechanize.get("http://www.google.com/search?&q="+keywords)

  return page
end

.instanceObject

Return the instance



7
8
9
# File 'lib/seo/position.rb', line 7

def self.instance
  @__instance__ ||= new
end