Welcome to the "trac"-ing site of soap4r!
[soap4r] [httpclient] [openpgp4u] [pkcs1] [logger] [csv] [vtr]

Ticket #463 (new defect)

Opened 9 months ago

Last modified 9 months ago

Typo in WSDL::XMLSchema::SimpleRestriction#parse_element

Reported by: user Assigned to: nahi
Priority: high Milestone: undefined
Component: wsdl4r Version: 1.5
Keywords: Cc:

Description

Using soap4r 1.5.8, I ran across this odd error:

irb> require 'rubygem'
irb> gem 'soap4r'
irb> require 'wsdl/xmlschema/parser'
irb> defined? WSDL::XMLSchema::MaxExclusive
=> "constant"
irb> sr = WSDL::XMLSchema::SimpleRestriction.new
=> #<WSDL::XMLSchema::SimpleRestriction:0x1cac4a6>
irb> men = WSDL::XMLSchema::MaxExclusiveName
=> #<XSD::QName:0x1cb1956 {http://www.w3.org/2001/XMLSchema}maxExclusive>
irb> sr.parse_element(men)
NameError: uninitialized constant WSDL::XMLSchema::SimpleRestriction::MaxExlusive
        from c:/ruby/lib/ruby/gems/1.8/gems/soap4r1.5.8/lib/wsdl/
                xmlSchema/simpleRestriction.rb:76:
in `parse_element'
        from (irb):11
irb>

Looking at simpleRestriction.rb, I found:

...
73:    when MaxInclusiveName
74:      MaxInclusive.new
75:    when MaxExclusiveName
76:      MaxExlusive.new
77:    when MinExclusiveName
78:      MinExlusive.new
79:    when MinInclusiveName
80:      MinInclusive.new
...

Pretty straight forward fix; line 76 should be MaxExclusive.new, line 78 should be MinExclusive.new.

Change History

03/05/08 03:31:27 changed by user

  • component changed from soap4r to wsdl4r.

Further typos?

wsdl\xmlschema\simpleRestriction.rb:

...
25:  attr_accessor :maxinclusive
26:  attr_accessor :maxexlusive
27:  attr_accessor :minexlusive
28:  attr_accessor :mininclusive
...