连接到XMPPRoom

问题描述:

使用XMPPframework为iPhone创建聊天室。我试图将用户连接到某个聊天室,但我无法做到。连接到XMPPRoom

这是我的代码:

BOOL activado = [salaChat activate:[[self appDelegate] xmppStream]];  
[salaChat joinRoom]; 
[salaChat sendMessage:@"HELLO"]; 

BOOL unido = [salaChat isJoined]; 

作为salaChat一个XMMPPRoom对象。

“activado”永远是真的,但“unido”永远不会。

test_android是用户名,“retiro”是房间ID。也许错误在那里,但我尝试了很多方法,但仍然没有。

任何想法?

谢谢。

+0

伟大的教程,但它不使用XMMPPRooms。 – subharb

+0

为什么不尝试http://code.google.com/p/xmppframework/wiki/GettingStarted_iOS。它看起来更受欢迎的选择。 – Saurabh

+0

文档已从Google移至git。 https://github.com/robbiehanson/XMPPFramework/wiki –

好了,解决了这个问题,我是把错了房间的名称。

应该是“[email protected]”和昵称,即用户的昵称。