I am having trouble getting certain aspects of a soap client working using abcl's java interop; most likely, this is the result of my ignorance of how certain things map from java to lisp. Any help would be appreciated!
The soap service is defined by this wsdl: http://chatsubo.net/~raison/usaepay.wsdl. The provider has a java library available for download at http://wiki.usaepay.com/developer/soap-1.4/howto/javajaxws. I have been able to use this library successfully in abcl (creating objects, calling methods on those objects, etc.), except when I need to call any of the methods defined in the java.rmi.Remote UeSoapServerPortType interface. For example, the method addCustomer is defined in the files http://chatsubo.net/~raison/UeSoapServerBindingStub.java and http://chatsubo.net/~raison/UeSoapServerPortType.java. No matter how I try to find the method (using jcall or various combinations of jmethod and class refs), I simply cannot find this method. What am I missing here?
Thanks for any assistance!
-Kevin
On Fri, Jan 4, 2013 at 6:47 PM, Kevin Raison raison@chatsubo.net wrote:
I am having trouble getting certain aspects of a soap client working using abcl's java interop; most likely, this is the result of my ignorance of how certain things map from java to lisp. Any help would be appreciated!
The soap service is defined by this wsdl: http://chatsubo.net/~raison/usaepay.wsdl. The provider has a java library available for download at http://wiki.usaepay.com/developer/soap-1.4/howto/javajaxws. I have been able to use this library successfully in abcl (creating objects, calling methods on those objects, etc.), except when I need to call any of the methods defined in the java.rmi.Remote UeSoapServerPortType interface. For example, the method addCustomer is defined in the files http://chatsubo.net/~raison/UeSoapServerBindingStub.java and http://chatsubo.net/~raison/UeSoapServerPortType.java. No matter how I try to find the method (using jcall or various combinations of jmethod and class refs), I simply cannot find this method. What am I missing here?
Thanks for any assistance!
Could you provide an example of how you are invoking those methods, and how you create the receiver object for those method calls?
Here are some examples of attempts to use jmethod to find the addCustomer method (all fail with no such method errors); see below for definitions of the class variables:
(jmethod *usaepay-class* "addCustomer" *token-class* *customer-class*) (jmethod *interface-class* "addCustomer" *token-class* *customer-class*) (jmethod (jclass "com.usaepay.api.jaxws.UeSoapServerBindingStub") *token-class* *customer-class*) (jmethod (jclass "com.usaepay.api.jaxws.UeSoapServerPortType_UeSoapServerPort_Client") "addCustomer" *token-class* *customer-class*)
And here are some examples of working calls:
(defparameter *usaepay-class* (jclass "com.usaepay.api.jaxws.usaepay")) (defparameter *string-class* (jclass "java.lang.String")) (defparameter *txn-class* (jclass "com.usaepay.api.jaxws.TransactionRequestObject")) (defparameter *txn-detail-class* (jclass "com.usaepay.api.jaxws.TransactionDetail")) (defparameter *cc-class* (jclass "com.usaepay.api.jaxws.CreditCardData")) (defparameter *double-class* (jclass "java.lang.Double")) (defparameter *token-class* (jclass "com.usaepay.api.jaxws.UeSecurityToken")) (defparameter *customer-class* (jclass "com.usaepay.api.jaxws.CustomerObject")) (defparameter *interface-class* (jclass "com.usaepay.api.jaxws.UeSoapServerPortType"))
(let* ((get-client-method (jmethod *usaepay-class* "getClient")) (get-token-method (jmethod *usaepay-class* "getToken" *string-class* *string-class* *string-class*)) (client (jcall get-client-method nil)) (token (jcall get-token-method nil key pin ip))) (let* ((request (jnew (jconstructor *txn-class*))) (details (jnew (jconstructor *txn-detail-class*))) (cc (jnew (jconstructor *cc-class*))) (amount (jnew *double-class* "12.30"))) (format t "Working with~% ~A~% ~A~% ~A~%" request details cc) (jcall (jmethod *txn-class* "setAccountHolder" *string-class*) request "Tester John") (jcall (jmethod *txn-detail-class* "setDescription" *string-class*) details "Test txn") (jcall "setAmount" details amount) (jcall (jmethod *txn-class* "setDetails" *txn-detail-class*) request details) (jcall (jmethod *cc-class* "setAvsStreet" *string-class*) cc "123 Elm St.") (values request details cc))))
Cheers, Kevin
On 01/04/2013 10:16 AM, Alessio Stalla wrote:
On Fri, Jan 4, 2013 at 6:47 PM, Kevin Raison raison@chatsubo.net wrote:
I am having trouble getting certain aspects of a soap client working using abcl's java interop; most likely, this is the result of my ignorance of how certain things map from java to lisp. Any help would be appreciated!
The soap service is defined by this wsdl: http://chatsubo.net/~raison/usaepay.wsdl. The provider has a java library available for download at http://wiki.usaepay.com/developer/soap-1.4/howto/javajaxws. I have been able to use this library successfully in abcl (creating objects, calling methods on those objects, etc.), except when I need to call any of the methods defined in the java.rmi.Remote UeSoapServerPortType interface. For example, the method addCustomer is defined in the files http://chatsubo.net/~raison/UeSoapServerBindingStub.java and http://chatsubo.net/~raison/UeSoapServerPortType.java. No matter how I try to find the method (using jcall or various combinations of jmethod and class refs), I simply cannot find this method. What am I missing here?
Thanks for any assistance!
Could you provide an example of how you are invoking those methods, and how you create the receiver object for those method calls?
armedbear-devel@common-lisp.net