14.4. SOAP::SerializerSOAP::Serializer does not need to be used directly except when autotyping is enabled. It allows you to specify types for your data. You can specify a type with SOAP::Data, with code similar to the following: SOAP::Data->type(something => [ ... ]) When serialization is reached, SOAP::Lite will attempt to serialize your data with the as_something method, if such a method exists. If you don't create an as_something method, no serialization will occur. You can create as_something with the following: sub SOAP::Serializer::as_something { my $self = shift; my($key, $val) = @_; ... return [$key, {'xsi:type' => 'xsd:something', %attr}, $val]; } Copyright © 2002 O'Reilly & Associates. All rights reserved. |
|