Sha256: df27a0c871a939d56dd9d05a58efa9a7f72ec60c65a8d1e8e548097e819b1ac1

Contents?: true

Size: 499 Bytes

Versions: 7

Compression:

Stored size: 499 Bytes

Contents

require 'AddMappingRegistry.rb'
require 'AddServant.rb'

class AddPortType
  def initialize()
    @sum = 0
  end

  def add(request)
    if (request.value > 100)
      fault = AddFault.new("Value #{request.value} is too large", "Critical")
      raise fault
    end

    if (request.value < 0)
      fault = NegativeValueFault.new("Value #{request.value} is negative", "Fatal")
      raise fault
    end

    @sum += request.value
    return AddResponse.new(@sum)
  end
end

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
soap4r-spox-1.6.0 sample/howto/wsdl_fault/multifault/AddServiceImpl.rb
soap4r-ruby1.9-2.0.5 sample/howto/wsdl_fault/multifault/AddServiceImpl.rb
soap4r-ruby1.9-2.0.3 sample/howto/wsdl_fault/multifault/AddServiceImpl.rb
soap4r-ruby1.9-2.0.2 sample/howto/wsdl_fault/multifault/AddServiceImpl.rb
soap4r-ruby1.9-2.0.1 sample/howto/wsdl_fault/multifault/AddServiceImpl.rb
soap4r-ruby1.9-2.0.0 sample/howto/wsdl_fault/multifault/AddServiceImpl.rb
soap4r-ruby1.9-1.0.0 sample/howto/wsdl_fault/multifault/AddServiceImpl.rb