Class: Diggr::Comment
- Inherits:
-
Object
- Object
- Diggr::Comment
- Defined in:
- lib/diggr/response_classes/comment.rb
Instance Attribute Summary collapse
-
#content ⇒ Object
Returns the value of attribute content.
-
#date ⇒ Object
Returns the value of attribute date.
-
#down ⇒ Object
Returns the value of attribute down.
-
#id ⇒ Object
Returns the value of attribute id.
-
#level ⇒ Object
Returns the value of attribute level.
-
#replies ⇒ Object
Returns the value of attribute replies.
-
#replyto ⇒ Object
Returns the value of attribute replyto.
-
#root ⇒ Object
Returns the value of attribute root.
-
#story ⇒ Object
Returns the value of attribute story.
-
#up ⇒ Object
Returns the value of attribute up.
-
#user ⇒ Object
Returns the value of attribute user.
Class Method Summary collapse
Instance Attribute Details
#content ⇒ Object
Returns the value of attribute content.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def content @content end |
#date ⇒ Object
Returns the value of attribute date.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def date @date end |
#down ⇒ Object
Returns the value of attribute down.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def down @down end |
#id ⇒ Object
Returns the value of attribute id.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def id @id end |
#level ⇒ Object
Returns the value of attribute level.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def level @level end |
#replies ⇒ Object
Returns the value of attribute replies.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def replies @replies end |
#replyto ⇒ Object
Returns the value of attribute replyto.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def replyto @replyto end |
#root ⇒ Object
Returns the value of attribute root.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def root @root end |
#story ⇒ Object
Returns the value of attribute story.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def story @story end |
#up ⇒ Object
Returns the value of attribute up.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def up @up end |
#user ⇒ Object
Returns the value of attribute user.
3 4 5 |
# File 'lib/diggr/response_classes/comment.rb', line 3 def user @user end |
Class Method Details
.new_from_parsed_json(data) ⇒ Object
5 6 7 8 9 10 11 12 13 |
# File 'lib/diggr/response_classes/comment.rb', line 5 def self.new_from_parsed_json(data) comment = Comment.new data.each do |key,val| comment.send("#{key}=",val) end comment end |