Mobile Designer Multi-Build with external Axis2 libraries

Hi All:

I have an app that I’ve built in Mobile Designer. It calls a SOAP Web Service that I built with ApplinX. When I run it in Phoney (not using the Ant script), it works just fine. When I attempt to build the app in MultiBuild, I receive a large number of errors related to the fact that the compile/build can’t find classes in org.apache.axis2.

I’ve experimented with different settings for the’ project.reshandler.additional.libs.path’ variable in build.xml to no avail.

Also, is there any way to keep the Ant build scripts from overwriting the .classpath file in the Eclipse project every time I run it?

Any help you could give me would be greatly appreciated. Thanks!

Best Regards, Mark Braukhoff

The short answer to the first question is that it can’t be done. Part of the longer answer is that the org.apache.axis2 library is not supported for J2ME, so when you try to create your stub classes using the wsdl2java that comes as part of Axis2 you will end up with object references that are non-existant in the JSR 172 space. In Phoney you can just specify a classpath to the Axis2 libraries and run, as Phoney uses J2SE under the hood. Building a bundle, however, is not as simple.

Currently there is no simple way to stop the Activation process from overwriting your .classpath file. There has been some success in setting the file as you want it and then changing the file property to “read-only” but that doesn’t always stop it so I suggest you keep a copy around and just copy it back when things go awry.

Spencer

Hi Mark,

I’ve used SOAP several times to consume Business Data from IS. My experience, the way it worked for me is:

  •    Create a Webservice that only provides objects that are supported by J2ME!
    

find the documentation here:
http://www.oracle.com/technetwork/java/webservices-138799.html

  •    In your mobile app you can use the oracle mobile SDK to create the stub classes
    

http://www.oracle.com/technetwork/java/javame/javamobile/download/sdk/index.html
How to do that you may have look at the NATIVEUIsoap sample app. (run wscompile.exe and providing a WSDL)

  •    Important is also that although you have defined an object in WSDL as optional you have to provide it (at least an empty string). Otherwise the app will throw some error.
    

Kind Regards

Marco