Class: Topsy::Author
- Inherits:
-
Object
- Object
- Topsy::Author
- Defined in:
- lib/rtopsy/author.rb
Instance Attribute Summary collapse
-
#description ⇒ Object
Returns the value of attribute description.
-
#hits ⇒ Object
Returns the value of attribute hits.
-
#influence_level ⇒ Object
Returns the value of attribute influence_level.
-
#name ⇒ Object
Returns the value of attribute name.
-
#nick ⇒ Object
Returns the value of attribute nick.
-
#topsy_author_url ⇒ Object
Returns the value of attribute topsy_author_url.
-
#type ⇒ Object
Returns the value of attribute type.
-
#url ⇒ Object
Returns the value of attribute url.
Instance Method Summary collapse
-
#initialize(hash) ⇒ Author
constructor
A new instance of Author.
- #to_s ⇒ Object
Constructor Details
#initialize(hash) ⇒ Author
Returns a new instance of Author.
24 25 26 27 28 |
# File 'lib/rtopsy/author.rb', line 24 def initialize(hash) hash.each do |key, value| instance_variable_set("@#{key}", value) end end |
Instance Attribute Details
#description ⇒ Object
Returns the value of attribute description.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def description @description end |
#hits ⇒ Object
Returns the value of attribute hits.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def hits @hits end |
#influence_level ⇒ Object
Returns the value of attribute influence_level.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def influence_level @influence_level end |
#name ⇒ Object
Returns the value of attribute name.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def name @name end |
#nick ⇒ Object
Returns the value of attribute nick.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def nick @nick end |
#topsy_author_url ⇒ Object
Returns the value of attribute topsy_author_url.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def @topsy_author_url end |
#type ⇒ Object
Returns the value of attribute type.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def type @type end |
#url ⇒ Object
Returns the value of attribute url.
18 19 20 |
# File 'lib/rtopsy/author.rb', line 18 def url @url end |
Instance Method Details
#to_s ⇒ Object
20 21 22 |
# File 'lib/rtopsy/author.rb', line 20 def to_s "Topsy Author: #{name}, @#{nick}, #{}" end |