ISerializerOutput::SerializeValue Method

HRESULT SerializeValue([in] VARIANT * v, [in] BSTR Name, [in] BSTR NameNS);

This takes a Variant value and serializes it within the specified name [and namespace]. multi-ref encoding rules are applied as needed. The serializerFactory is used to find the appropriate serializer object.

 

Parameters

v
VARIANT *, [in]: The value to serialize
Name
BSTR, [in]: The name for the value
NameNS
BSTR, [in]: The namespace for the value name

 

Return Values

 

Sample Code

Visual Basic Class File

Implements ISoapSerializer

Private Const NS = "http://auth.example.org/2001/01/"

Private Sub ISoapSerializer_Serialize(  Val As Variant, _
                                        ByVal ctx As PocketSOAP.ISerializerContext, _
                                        ByVal dest As PocketSOAP.ISerializerOutput)
    Dim a As AuthInfo
    Set a = Val
	' authInfo has two properties, which are strings
	dest.SerializeValue a.Type, "type", NS
	dest.SerializeValue a.Key,  "type", NS
End Sub

 

See Also

The ISerializerOutput Interface | 

 

 

Copyright

Copyright © Simon Fell, 2000-2004. All rights reserved.