require 'chilkat'
xml = Chilkat::CkXml.new()
xml.put_Tag("soapenv:Envelope")
xml.AddAttribute("xmlns:intf","http://data.webservice.workshop.vivid.nl")
xml.AddAttribute("xmlns:soapenv","http://schemas.xmlsoap.org/soap/envelope/")
xml.UpdateChildContent("soapenv:Header","")
xml.UpdateChildContent("soapenv:Body|intf:getCompleteComponent|intf:vrid","xml")
xml.UpdateChildContent("soapenv:Body|intf:getCompleteComponent|intf:typeId","xml")
xml.UpdateChildContent("soapenv:Body|intf:getCompleteComponent|intf:si","xml")
xml.UpdateChildContent("soapenv:Body|intf:getCompleteComponent|intf:st","xml")
xml.UpdateChildContent("soapenv:Body|intf:getCompleteComponent|intf:language","xml")
# In a SOAP HTTP request, including the XML declaration (<?xml version="1.0" encoding="UTF-8"?>) in the XML body is generally not required.
xml.put_EmitXmlDecl(false)
soapRequestBody = xml.getXml()
endpoint = "http://www.haynespro-services.com/workshopServices3/services/DataServiceEndpoint"
soapAction = ""# For SOAP requests, the standard Content-Type is usually set to "text/xml" or "application/soap+xml"
contentType = "text/xml"
http = Chilkat::CkHttp.new()
http.ClearHeaders()
http.SetRequestHeader("Content-Type",contentType)
http.SetRequestHeader("SOAPAction",soapAction)
# resp is a CkHttpResponse
resp = http.PostXml(endpoint,soapRequestBody,"utf-8")
if (http.get_LastMethodSuccess() == false)
print http.lastErrorText() + "\n";
print"Failed to send SOAP request." + "\n";
exitend# Get the XML response body.
responseXml = Chilkat::CkXml.new()
resp.GetBodyXml(responseXml)
statusCode = resp.get_StatusCode()
print"response status code: " + statusCode.to_s() + "\n";
# If the status code does not indicate succcess, then show the response XML,
# which probably contains error information.if (statusCode != 200)
print responseXml.getXml() + "\n";
exitendprint responseXml.getXml() + "\n";
# Parse the successful SOAP response XML.# This is a sample of the response XML, but the namespace prefixes will be different.
# We can parse the result using "*" for the namespace prefixes (see below).
componentImageId = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:componentImageId")
connectorSideImage = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:connectorSideImage")
flashVarsString = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:flashVarsString")
xvalue = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:graph|*:points|*:item|*:xvalue")
ymaxvalue = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:graph|*:points|*:item|*:ymaxvalue")
yminvalue = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:graph|*:points|*:item|*:yminvalue")
xaxis = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:graph|*:xaxis")
yaxis = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:graph|*:yaxis")
name = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:name")
sortOrder = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:sortOrder")
value1 = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:table|*:header|*:value1")
value2 = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:table|*:header|*:value2")
value1 = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:table|*:rows|*:item|*:value1")
value2 = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:table|*:rows|*:item|*:value2")
text = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:text")
title = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:title")
v_type = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:type")
drawRight = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:wirediagram2|*:nodeArray|*:item|*:drawRight")
image = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:wirediagram2|*:nodeArray|*:item|*:image")
name = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:wirediagram2|*:nodeArray|*:item|*:name")
pinname = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:wirediagram2|*:nodeArray|*:item|*:pinname")
sort_order = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:wirediagram2|*:nodeArray|*:item|*:sort_order")
v_type = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:diagnosisSteps|*:item|*:wirediagram2|*:nodeArray|*:item|*:type")
title = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:diagnosisSteps|*:item|*:title")
ecuSideImage = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:ecuSideImage")
description = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:genericParts|*:item|*:description")
id = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:genericParts|*:item|*:id")
mandatory = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:genericParts|*:item|*:mandatory")
hasLocationSystems = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:hasLocationSystems")
description = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:description")
hyperlink = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:hyperlink")
name = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:name")
pinName = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:pinName")
pinNumber = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:pinNumber")
si = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:si")
st = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:st")
wireColor1 = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:wireColor1")
wireColor2 = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:pinTable|*:componentsArray|*:item|*:wireColor2")
renderable = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:renderable")
subnetXml = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:completeComponent|*:subnetXml")
confirmationLink = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:status|*:confirmationLink")
statusCode = responseXml.getChildContent("*:Body|*:getCompleteComponentResponse|*:getCompleteComponentReturn|*:status|*:statusCode")