1 7 8 package test.wsdl.any; 9 10 import org.apache.axis.message.MessageElement; 11 12 public class SoapBindingImpl implements test.wsdl.any.Soap{ 13 public test.wsdl.any.QueryResult query(java.lang.String queryString) throws java.rmi.RemoteException { 14 QueryResult qr = new QueryResult(); 15 qr.setDone(true); 16 17 SObject record = new SObject(); 18 record.setType("Contact"); 19 record.setId("00330000006jryXAAQ"); 20 21 try{ 22 MessageElement m1 = new MessageElement("Id", "sf", "urn:partner.soap.sforce.com"); 23 MessageElement m2 = new MessageElement("FirstName", "sf", "urn:partner.soap.sforce.com"); 24 MessageElement m3 = new MessageElement("LastName", "sf", "urn:partner.soap.sforce.com"); 25 m1.addTextNode("00330000006jryXAAQ"); 26 m2.addTextNode("Fred"); 27 m3.addTextNode("A>B"); 28 MessageElement[] me = new MessageElement[]{m1, m2, m3}; 29 record.set_any(me); 30 } catch(javax.xml.soap.SOAPException e){ 31 32 } 33 34 SObject[] records = new SObject[]{record}; 35 qr.setRecords(records); 36 37 qr.setSize(1); 38 39 return qr; 40 } 41 42 } 43 | Popular Tags |