EventBus is a library of Greenbot . This is very simple for all users how to implement and its basic use. Here I will also share examples for better understanding. What is EventBus? EventBus is subscribed/publish event bus to communication between components with limited lines of code, in short, its bus for events transfers the data between one activity(class) to another to reflect the changes based on our needs. That makes the data exchange between components like Activity, Fragment, Services, and any kind of backgrounds threads pretty easy. EventBus can handle the threading for us: events can be posted in threads different from the posting thread. Common use can be dealing with UI changes. In Android, UI changes must be done in the Main(UI) thread. In other words, networking or more time-consuming task cannot be handled in the Main thread, for that we must use AsyncTask or Handler to make it more smooth. Now we have one more options use EventBus to change the UI po...
I was running Web Service successfully in Year-2010 and already post into many forums. But some of forum/sites had removed that post So I thought to post once again for those who still facing problem.
First I am giving simple code that will help you.
First create Dynamic Web project using Eclipse IDE.
and create one class : Converter.java
This class place under this package: org.web.prashant.adesara
now select Converter.java file and do right click and New--> Other--> Web Services--> and select Web Service
There are two option
1. Web Service Type
2. Client Type
in first point you have to select slider as a Start Service:
and in second point you have to select slider as a Test Client
and click on Finish button.
You web Service will run automatically. Just check your webservice will work properly or not.
Main Steps:
Now most important thing is you have to download ksoap2 jar file
Now Create Android Project
and copy paste this code
And run it will give sum of two value
If you are satisfied then please give your comments.
Thanks for your Interest!!!
How to findout thee IP adress of glassfish server in URL , instead of Localhost. please explain.
ReplyDelete