Class: FacebookScrapper::Person

Inherits:
Object
  • Object
show all
Defined in:
lib/facebook_scrapper/person.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializePerson

Returns a new instance of Person.



5
6
7
8
9
# File 'lib/facebook_scrapper/person.rb', line 5

def initialize
  self.name = ""
  self.pofile_link = ""
  self.add_as_friend_link = ""
end

Instance Attribute Details

Returns the value of attribute add_as_friend_link.



3
4
5
# File 'lib/facebook_scrapper/person.rb', line 3

def add_as_friend_link
  @add_as_friend_link
end

#nameObject

Returns the value of attribute name.



3
4
5
# File 'lib/facebook_scrapper/person.rb', line 3

def name
  @name
end

Returns the value of attribute pofile_link.



3
4
5
# File 'lib/facebook_scrapper/person.rb', line 3

def pofile_link
  @pofile_link
end

Instance Method Details

#to_strObject



11
12
13
14
15
16
17
18
19
# File 'lib/facebook_scrapper/person.rb', line 11

def to_str
  s = ""
  s += "#{self.name}:\n"
  s += "Profile Link: #{self.pofile_link}"
  if self.add_as_friend_link != ""
    s += "Addlink ->: #{self.add_as_friend_link}"
  end
  return s
end