I am new to Android programming.I have completed the basics though and wish to learn XMPP for making a chat application on Android. I've gone through tutorials, but have not got the way to use a custom pc as server for the application.I want to use my laptop as a server for sending messages between 2 android devices.My laptop should be able to recieve and direct the messages between the two.Can anyone please help me get started?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
First of all, you need to install in your laptop a XMPP server. Here are a list of available ones. People used to say Openfire is easy to install and configure, but to production purposes Ejabberd (linux and mac only) seems to be more robust.
To develop your app, you can use Smack, which is large well documented, with code snapshots to connect to a server, create a chat, send and receive messages etc.