Sha256: dfec07a5f6051e36e8a4968d859fde1919d95924ecf4629397d905474b959760

Contents?: true

Size: 1.54 KB

Versions: 38

Compression:

Stored size: 1.54 KB

Contents

# encoding: ASCII-8BIT
# SOAP4R - A method definition
# Copyright (C) 2000-2007  NAKAMURA, Hiroshi <nahi@ruby-lang.org>.

# This program is copyrighted free software by NAKAMURA, Hiroshi.  You can
# redistribute it and/or modify it under the same terms of Ruby's license;
# either the dual license version in 2003, or any later version.


module SOAP
module RPC


class MethodDef
  attr_reader :name
  attr_reader :soapaction
  attr_reader :qname
  attr_accessor :style
  attr_accessor :inputuse
  attr_accessor :outputuse
  attr_reader :parameters
  attr_reader :faults

  def initialize(name, soapaction, qname)
    @name = name
    @soapaction = soapaction
    @qname = qname
    @style = @inputuse = @outputuse = nil
    @parameters = []
    @faults = {}
  end

  def add_parameter(io_type, name, qname, mapped_class)
    @parameters << Parameter.new(io_type, name, qname, mapped_class)
  end

  def self.to_param(param)
    if param.respond_to?(:io_type)
      param
    else
      io_type, name, param_type = param
      mapped_class_str, nsdef, namedef = param_type
      if nsdef && namedef
        qname = XSD::QName.new(nsdef, namedef)
      else
        qname = nil
      end
      MethodDef::Parameter.new(io_type.to_sym, name, qname, mapped_class_str)
    end
  end

  class Parameter
    attr_reader :io_type
    attr_reader :name
    attr_reader :qname
    attr_reader :mapped_class

    def initialize(io_type, name, qname, mapped_class)
      @io_type = io_type
      @name = name
      @qname = qname
      @mapped_class = mapped_class
    end
  end
end


end
end

Version data entries

38 entries across 38 versions & 10 rubygems

Version Path
soybean-2.5.5 vendor/soap4r/soap/rpc/method_def.rb
malagant-soap4r-1.5.8.20141127181857 lib/soap/rpc/methodDef.rb
rtiss_soap4r-1.6.1 lib/soap/rpc/methodDef.rb
rtiss_soap4r-1.6.0 lib/soap/rpc/methodDef.rb
eSpace_soap4r-1.5.8 lib/soap/rpc/methodDef.rb
soap4r-ruby19-1.5.9 lib/soap/rpc/methodDef.rb
tomdz-soap4r-1.5.8.20120202093209 lib/soap/rpc/methodDef.rb
soap5r-2.0.3 lib/soap/rpc/methodDef.rb
soap5r-2.0.2 lib/soap/rpc/methodDef.rb
soap5r-2.0.1 lib/soap/rpc/methodDef.rb
soap5r-2.0.0 lib/soap/rpc/methodDef.rb
soap5r-2.0.0.20120130130121 lib/soap/rpc/methodDef.rb
soap4r-sgonyea-1.5.9 lib/soap/rpc/methodDef.rb
sunteya-soap4r-1.5.8.0 lib/soap/rpc/methodDef.rb
soybean-2.5.4 vendor/soap4r/soap/rpc/method_def.rb
tomdz-soap4r-1.5.8.20111103171510 lib/soap/rpc/methodDef.rb
soybean-2.5.3 vendor/soap4r/soap/rpc/method_def.rb
soybean-2.5.2 vendor/soap4r/soap/rpc/method_def.rb
soybean-2.5.1 vendor/soap4r/soap/rpc/method_def.rb
soybean-2.5.0 vendor/soap4r/soap/rpc/method_def.rb