Module: PagoPA::SOAP

Defined in:
lib/pago_pa/soap.rb,
lib/pago_pa/soap/version.rb,
lib/pago_pa/soap/version.rb,
lib/pago_pa/soap/message/rt.rb,
lib/pago_pa/soap/message/rpt.rb,
lib/pago_pa/soap/wsdl_loader.rb,
lib/pago_pa/soap/configurable.rb,
lib/pago_pa/soap/message/payer.rb,
lib/pago_pa/soap/message/domain.rb,
lib/pago_pa/soap/message/payment.rb,
lib/pago_pa/soap/message/institution.rb,
lib/pago_pa/soap/message/single_payment.rb

Defined Under Namespace

Modules: Message Classes: Configurable, WSDLLoader

Constant Summary collapse

VERSION =
"0.1.0"

Class Method Summary collapse

Class Method Details

.buildObject

API client based on configured options Configurable



12
13
14
15
# File 'lib/pago_pa/soap.rb', line 12

def build
  return @build if defined?(@build)
  @build = PagoPA::SOAP::WSDLLoader.new(options)
end

.configObject



13
14
15
# File 'lib/pago_pa/soap/configurable.rb', line 13

def config
  @config ||= Configurable.new
end

.configure {|config| ... } ⇒ Object

Set configuration options using a block

Yields:



18
19
20
# File 'lib/pago_pa/soap/configurable.rb', line 18

def configure
  yield(config)
end

.keysArray

List of configurable keys for Pagoparb::Client

Returns:

  • (Array)

    of option keys



7
8
9
10
11
# File 'lib/pago_pa/soap/configurable.rb', line 7

def keys
  @keys ||= %i[
    namespace wsdl_base wsdl_notify endpoint_base endpoint_notify
  ]
end

.optionsObject



7
8
9
# File 'lib/pago_pa/soap.rb', line 7

def options
  Hash[PagoPA::SOAP.keys.map { |key| [key, config.send(key)] }]
end