Class: Rsift::Comment

Inherits:
Model
  • Object
show all
Defined in:
lib/rsift/comment.rb

Instance Method Summary collapse

Constructor Details

#initialize(url, key, username) ⇒ Comment

Returns a new instance of Comment.



6
7
8
9
10
# File 'lib/rsift/comment.rb', line 6

def initialize(url, key, username)
  @format = "json"
  @section = "comment"
  super(url, key, username)
end

Instance Method Details

#do(verb, opts = {}) ⇒ Object



12
13
14
15
# File 'lib/rsift/comment.rb', line 12

def do(verb, opts = {})
  get("#{@section}/#{verb}.#{@format}?&"+
      Rsift::escape_options(opts).join("&"))
end

#get(path) ⇒ Object



17
18
19
# File 'lib/rsift/comment.rb', line 17

def get(path)
  @conn.get(path)
end