Hi everyone.
I've been deeply reading the getting started with Tuscany, and i''m in
need of explanations on some points:
- What does the Tuscany SCA Data Collection stands for? What's the
difference between an org.apache.tuscany.sca.data.collection.Entry object
and a java.util.Map object?
- In the shopping Cart implementation, is it because the component use
the atom binding, that put, post and delete methods are defined? What about
the keyring system key = "cart-" + UUID.randomUUID().toString(); in the
post method? What is it used for?
In order to handle the shopping cart items posting, and the shopping cart
total request from the android app, I'm trying to use the Abdera project.
As it's going to be run from a mobile platform, i intend to build only the
needed part of Abdera, and export it to android as a Dex file.
I'll be posting the cart items like this:
>
>
> Abdera abdera = new Abdera();
> AbderaClient client = new AbderaClient(abdera);
>
> Entry entry = abdera.newEntry();
>
> entry.setContent("<entry xmlns='http://www.w3.org/2005/Atom'>" +
> "<title>item</title>" +
> "<content type='text/xml'>" +
> "<Item xmlns='http://services/'>" +
> "<name xmlns=''>" + item.getName()+ "</name>" +
> "<price xmlns=''>" +item.getPrice()+"</price>" +
> "</Item></content></entry>");
>
> ClientResponse resp = client.post(ServiceURI,entry);
>
And this requires the following classes:
> org.apache.abdera.Abdera;
> org.apache.abdera.model.Entry;
> org.apache.abdera.model.Feed;
> org.apache.abdera.protocol.Response.ResponseType;
> org.apache.abdera.protocol.client.AbderaClient;
> org.apache.abdera.protocol.client.ClientResponse;
I'd like to know if there's a tool i can use to quickly and easily pack
those classes with their dependencies in a jar file, before sealing them in
a dex file using the android dx utility.
Surely all this will imply a switch of the shopping cart's binding from atom
to atom-abdera.
Apart from answers to my questions, feel free guys to post any comment or
helpful advice.
Cdlt;
--
Lookman SANNI;