Class: Ucenter::Tools::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/ucenter/tools/base.rb

Overview

The Base class of API

Direct Known Subclasses

Url, Xml

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ Base

Returns a new instance of Base.



5
6
7
# File 'lib/ucenter/tools/base.rb', line 5

def initialize(client)
  @client = client
end

Instance Method Details

#get(path, opts = {}, &block) ⇒ Object



9
10
11
# File 'lib/ucenter/tools/base.rb', line 9

def get(path, opts={}, &block)
  request(:get, path, opts, &block)
end

#post(path, opts = {}, &block) ⇒ Object



13
14
15
# File 'lib/ucenter/tools/base.rb', line 13

def post(path, opts={}, &block)
  request(:post, path, opts, &block)
end