PocketSOAP : Migration Guide
Migrating from 0.9.x code
The 1.1 version has a completely new set of interfaces, some similar to the previous ones, some not. The core pocketSOAP engine can be run side by side with the 0.9.x engine, if the 0.9.x code uses either early binding or uses the fully qualified progID ( i.e. pocketSOAP.Envelope.1 ). the pocketSOAP.Envelope progID (without the .1) will now create an instance of the new .2 envelope. The high level proxy object continues to expose the same interfaces, however it now calls the new engine not the old one, depending on how complex your calls are, this may or may not cause problems. Note however that the 0.9.x version and the 1.1 version cannot be run in the same process.The object model surrounding the envelope and parameters has changed slightly, and has been modified to make creating nested complex types easier, e.g.
pocketSOAP 0.9.x code
dim e set e = CreateObject("PocketSOAP.Envelope.1") e.methodName = "getQuote" e.URI = "urn:xmethods-delayed-quotes" e.CreateParameter "symbol", "MSFT", "xsd:string" dim t, r set t = CreateObject("PocketSOAP.HTTPTransport") t.Send "http://services.xmethods.net/soap", e.serialize e.Parse t.Receive wscript.echo e.Parameters.Item(0).ValueThe equivilent code in 1.1 would be
dim e set e = CreateObject("PocketSOAP.Envelope.2") e.SetMethod "getQuote", "urn:xmethods-delayed-quotes" e.Parameters.Create "symbol", "MSFT" dim t, r set t = CreateObject("PocketSOAP.HTTPTransport.2") t.Send "http://services.xmethods.net/soap", e.serialize e.Parse t wscript.echo e.Parameters.Item(0).ValueNote that
- The calls to methodName and URI have been replaced with a call to SetMethod [however methodName and URI are still there if you'd perfer them].
- e.CreateParameter is now e.Parameters.Create this really comes into its own with nested types.
- the transport object is now directly passed to the parse function.