Module: SIBAApi

Defined in:
lib/siba_api.rb,
lib/siba_api/api.rb,
lib/siba_api/client.rb,
lib/siba_api/version.rb,
lib/siba_api/constants.rb,
lib/siba_api/api_exceptions.rb,
lib/siba_api/http_status_codes.rb

Overview

Implementation of available methods for SIBA API

Defined Under Namespace

Modules: ApiExceptions, Constants, HttpStatusCodes Classes: API, Client, Error

Constant Summary collapse

LIBNAME =
'siba_api'
LIBDIR =
File.expand_path(LIBNAME.to_s, __dir__)
VERSION =
'0.1.5'

Class Method Summary collapse

Class Method Details

.default_middleware(options = {}) ⇒ Proc

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Default middleware stack that uses default adapter as specified by configuration setup

Returns:

  • (Proc)


33
34
35
# File 'lib/siba_api.rb', line 33

def default_middleware(options = {})
  Middleware.default(options)
end

.method_missing(method_name, *args, &block) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Delegate to SIBAApi::Client



40
41
42
43
44
45
46
# File 'lib/siba_api.rb', line 40

def method_missing(method_name, *args, &block)
  if new.respond_to?(method_name)
    new.send(method_name, *args, &block)
  else
    super.respond_to_missing?
  end
end

.new(options = {}, &block) ⇒ SEFApi::Client

Alias for SIBAApi::Client.new

Parameters:

  • options (Hash) (defaults to: {})

    the configuration options

Returns:

  • (SEFApi::Client)


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

def new(options = {}, &block)
  Client.new(options, &block)
end

.respond_to_missing?(method_name, include_private = false) ⇒ Boolean

Returns:

  • (Boolean)


48
49
50
# File 'lib/siba_api.rb', line 48

def respond_to_missing?(method_name, include_private = false)
  new.respond_to?(method_name, include_private) || super(method_name, include_private)
end