| Class | SOAP::SOAPReference |
| In: |
soap/baseData.rb
|
| Parent: | XSD::NSDBase |
Convenience datatypes.
| refid | [RW] |
# File soap/baseData.rb, line 160 def self.decode(elename, refidstr) if /\A#(.*)\z/ =~ refidstr refid = $1 elsif /\Acid:(.*)\z/ =~ refidstr refid = $1 else raise ArgumentError.new("illegal refid #{refidstr}") end d = super(elename) d.refid = refid d end
Override the definition in SOAPBasetype.
# File soap/baseData.rb, line 115 def initialize(obj = nil) super() @type = XSD::QName::EMPTY @refid = nil @obj = nil __setobj__(obj) if obj end
# File soap/baseData.rb, line 127 def __setobj__(obj) @obj = obj @refid = @obj.id || SOAPReference.create_refid(@obj) @obj.id = @refid unless @obj.id @obj.precedents << self # Copies NSDBase information @obj.type = @type unless @obj.type end
Why don‘t I use delegate.rb? -> delegate requires target object type at initialize time. Why don‘t I use forwardable.rb? -> forwardable requires a list of forwarding methods.
ToDo: Maybe I should use forwardable.rb and give it a methods list like delegate.rb…
# File soap/baseData.rb, line 144 def method_missing(msg_id, *params) if @obj @obj.send(msg_id, *params) else nil end end
ruby-doc.org is hosted and run by James Britt and Happy Camper Studios, a Ruby application development company in Phoenix, Arizona. Ruby-doc.org was created in 2002 to promote the Ruby language and to help other Ruby hackers.
Documentation content on ruby-doc.org is provided by remarkable members of the Ruby community.
For more information on the Ruby programming language, visit ruby-lang.org.
Want to help improve Ruby's API docs? See Ruby Documentation Guidelines.