class ZaifWrapper::Client::ZaifFutureApi
Public Instance Methods
method_missing(name, *args)
click to toggle source
# File lib/zaif_wrapper/client.rb, line 106 def method_missing(name, *args) if FUTURE_METHODS.include?(name.to_s) klass = class << self; self end klass.class_eval do define_method(name) do |body = []| path = name if body.length != 0 body.each do |param| path = path + "/#{param}" end end get_request(FUTURE_REQUEST_URL_BASE, path) end end if args.length == 1 __send__(name, args[0]) else __send__(name) end end end