Class: WEB_API::Auth

Inherits:
WebApi show all
Defined in:
lib/web_api/auth.rb

Direct Known Subclasses

Signed, Signed2

Instance Attribute Summary collapse

Attributes inherited from WebApi

#webmethods

Instance Method Summary collapse

Methods inherited from WebApi

#_url, #add, #method_missing, trace, trace=

Constructor Details

#initialize(auth, *args) ⇒ Auth

Returns a new instance of Auth.



18
19
20
21
# File 'lib/web_api/auth.rb', line 18

def initialize(auth, *args)
  @auth = auth
  super(*args)
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class WEB_API::WebApi

Instance Attribute Details

#authObject (readonly)

Returns the value of attribute auth.



17
18
19
# File 'lib/web_api/auth.rb', line 17

def auth
  @auth
end

Instance Method Details

#_add(method, uri, type) ⇒ Object



23
24
25
# File 'lib/web_api/auth.rb', line 23

def _add(method, uri, type)
  webmethods[method] = AuthMethod.new(@auth, uri, type)
end