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

root/branches/1_5/lib/wsdl/xmlSchema/all.rb

Revision 2015, 0.9 kB (checked in by nahi, 12 hours ago)
  • ruby-1.8.7 warning cleanups. closes #497.
  • Property svn:eol-style set to native
  • Property svn:keywords set to author date id revision
Line 
1 # WSDL4R - XMLSchema complexType definition for WSDL.
2 # Copyright (C) 2000-2007  NAKAMURA, Hiroshi <nahi@ruby-lang.org>.
3
4 # This program is copyrighted free software by NAKAMURA, Hiroshi.  You can
5 # redistribute it and/or modify it under the same terms of Ruby's license;
6 # either the dual license version in 2003, or any later version.
7
8
9 require 'wsdl/xmlSchema/content'
10
11
12 module WSDL
13 module XMLSchema
14
15
16 class All < Content
17   attr_reader :any
18
19   def initialize
20     super()
21     @any = nil
22   end
23
24   def have_any?
25     !!@any
26   end
27
28   def parse_element(element)
29     case element
30     when SequenceName
31       o = Sequence.new
32       @elements << o
33       o
34     when ChoiceName
35       o = Choice.new
36       @elements << o
37       o
38     when GroupName
39       o = Group.new
40       @elements << o
41       o
42     when AnyName
43       @any = Any.new
44       @elements << @any
45       @any
46     else
47       super(element)
48     end
49   end
50 end
51
52
53 end
54 end
Note: See TracBrowser for help on using the browser.