asmack

Facebook asmack xmpp client returns random numbers for roster

元气小坏坏 提交于 2020-01-01 07:06:06
问题 I followed the guidlines given in the following SO question to connect to facebook chat using xmpp and I am able to connect to facebook and pull the correct number of contacts but when it prints the contacts they are all random numbers @chat.facebook.com and all return offline. Android Facebook chat example project public void connectToFb() throws XMPPException { ConnectionConfiguration config = new ConnectionConfiguration("chat.facebook.com", 5222); config.setSASLAuthenticationEnabled(true);

How to send composing / is typing (Chat states) event in Multiuser chat / Group chat & One to One chat in xmpp android?

时光总嘲笑我的痴心妄想 提交于 2020-01-01 03:47:05
问题 I want send composing event in Group (Multiuser) chat in xmpp, I am using asmack library, I have done same functionality with One to One chat. I am using below code: mMessageEventManager = new MessageEventManager(XMPPConnectApplication.getInstance().getXmppConnection()); mMessageEventManager.addMessageEventNotificationListener(new MessageEventNotificationListener() { @Override public void offlineNotification(String arg0, String arg1) { } @Override public void displayedNotification(String arg0

XMPP “stream:error (conflict)” on login with (a)Smack

自闭症网瘾萝莉.ら 提交于 2019-12-30 04:24:05
问题 Currently i am working with xmpp/jabber chat for android.i just tried with Openfire and try to connect my jabber account.connection was successful.but i am not able to send any message.it shows some conflict error.please check the error log.give me a solution for this. Initializing connection to server eworks port 5222 Connected: true Creating entry for buddy 'testuser2' with name testuser2 Sending mesage 'Hello mate' to user testuser2@eworks Buddy:testuser2 - Status:null stream:error

asmack library behaving differently when installed from Eclipse vs installed from apk in Android

不问归期 提交于 2019-12-25 11:13:42
问题 I am developing a chat app in Android which runs in all versions of Android ( starting from 2.3.5 to the latest kitkat) and every thing is working fine when it comes to chatting, but I am facing one BIG issue. The issue is when I generate the apk and install the apk in Android mobile (using package installer), the user goes offline in some time ( say in XYZ mins ).In S3 it is 40 mins and in S5 it is 30 mins and in htc desire hd it is 20 mins after which the user is disconnected. But when I

Asmack File Sending Error 503 Type = cancel with openfire

风格不统一 提交于 2019-12-25 08:16:41
问题 Login Code. Login done successfully. String host=AppContext.HOST;//myHost String [] params={"a1","aa"} int port=AppContext.PORT;//My Port 2777 String service=AppContext.SERVICE; //service = smack ConnectionConfiguration connConfig = new ConnectionConfiguration( host, port, service); connConfig.setDebuggerEnabled(true); Connection.DEBUG_ENABLED = true; connConfig.setSASLAuthenticationEnabled(true); XMPPConnection connection = new XMPPConnection(connConfig); Log.e("XMPP LoginActivity Username "

Android Smack MessageEventManager not compiling

拜拜、爱过 提交于 2019-12-25 04:39:37
问题 I am using smack API with openfire server to make an android app. I am trying to implement a MessageEventManager and MessageEventProvider to my app so it will tell me if the message was delivered or not though when i try to declare it a MessageEventManager, it is not compiling and tells me to create that class, What can i do? i have the following dependencies in my gradle: dependencies { compile fileTree(include: ['*.jar'], dir: 'libs') compile 'com.android.support:appcompat-v7:22.1.1'

File transfer in group chat with XMPP

霸气de小男生 提交于 2019-12-25 02:38:17
问题 I am using group chat with open fire. i can able to send messages but how to send file to group with Smack library. i can able to send file to single user with below but i don't know how to send to group chat (MUC) so all users in room will receive that file OutgoingFileTransfer transfer = manager.createOutgoingFileTransfer("usre2@myHost/Smack"); 回答1: Use XEP-0066: Out of Band Data - this is small extension to standard groupchat message with url and description. Other users will receive link

Getting bad request 400 error using asmack in android

ε祈祈猫儿з 提交于 2019-12-24 17:25:02
问题 I am trying to register a new user using my XMPP client using asmack library in Android on ejabberd server. The problem is that I am getting following error & the user is not being created on the server: bad-request(400) at org.jivesoftware.smack.AccountManager.createAccount(AccountManager.java:243) at in.ui.MainActivity$1$1$1.run(MainActivity.java:316) at java.lang.Thread.run(Thread.java:841) Following is the code: _xmppUsername = XMPPConfig.getStringUserInfoValue (XMPPConfig.XMPP_CLIENT_ID)

How to send file between device using xmpp while chat

怎甘沉沦 提交于 2019-12-24 07:30:07
问题 Thanks for paying attention over the question... I am making a XMPP chat application with the help of ejabbered and asmack_4.1 library. I have installed a PSI client for windows to chat with the android device. I am able to perform text chat between devices. I am also able to send file from device to PSI client and PSI client to android device. But the problem is to send files device to device. I am using below code to send and receive files : File send : public void fileTransfer(String

Android asmack: stateChange never called

好久不见. 提交于 2019-12-24 05:24:05
问题 I am building a chat application using asmack xmpp client. Chat works fine and I have implemented ChatStateListener but stateChanged method never gets called. Currently to get composing status I am parsing the message xml. Below is the message format for composing,text, active. <message id='5ec7d' to='admin@testserver123.net' from='praveenraj@testserver123.net/682e3641' type='chat'><composing xmlns="http://jabber.org/protocol/chatstates" /></message> <message id='9a93f22' to='admin