robbiehanson / XMPPFramework

An XMPP Framework in Objective-C for Mac and iOS
Other
5.91k stars 2.09k forks source link

Cant fetch detail of NonPublic Persistant XMPPRoom #329

Open NileshTripathi opened 10 years ago

NileshTripathi commented 10 years ago

Hey robbiehanson,

I have already posted this question on google grouops, stackoverflow and then I came here with some hope that some one will help me.

I have already did enough R&D and then I am here to question something.

Please find below brief detail of the question

I have created a MembersOnly(non Public), Persistant Room. In which I have invited multiple occupants. Now I want to fetch detail of room for the user who were invited by the creator.

I tried this code :

XMPP requirement :

<iq from='hag66@shakespeare.lit/pda' id='ik3vs715' to='coven@chat.shakespeare.lit' type='get'>

iOS code on view will apear: NSXMLElement *query = [NSXMLElement elementWithName:@"query" xmlns:@"http://jabber.org/protocol/disco#info"];//

NSString *iqID = [[appDelegate xmppStream] generateUUID];

XMPPJID jID = self.room.roomJID; XMPPIQ element = [XMPPIQ iqWithType:@"get" to:jID elementID:iqID child:query]; [element addAttributeWithName:@"from" stringValue:[[[appDelegate xmppStream] myJID] full]]; [[appDelegate xmppStream] fetchInformationForGivenIQ:element];

This should provide me this kinda result, which is I am getting public rooms I have created but not for other non public rooms:

<iq from='coven@chat.shakespeare.lit' id='ik3vs715' to='hag66@shakespeare.lit/pda' type='result'>

feature var='http://jabber.org/protocol/muc'/> feature var='muc_passwordprotected'/> feature var='muc_hidden'/> feature var='muc_temporary'/> feature var='muc_open'/> feature var='muc_unmoderated'/> feature var='muc_nonanonymous'/> /query> /iq> But I am getting this result : iq xmlns="jabber:client" type="result" id="some ID" from="Group-ID" to="My Full JabberID"> query xmlns="http://jabber.org/protocol/disco#info"> feature var="http://jabber.org/protocol/disco#info"> /feature> /query> /iq> Can any one help me what I am doing wrong. I even tried different options like giving different affiliation and role to invitees, but still I am getting the above result. Hope you will help me. Thanks in advance.
NileshTripathi commented 10 years ago

Find stackoverflow link for proper visibility: http://stackoverflow.com/questions/22252257/cant-fetch-detail-of-xmpproom-from-the-server-xmpp-framework

And google groups link: https://groups.google.com/forum/#!topic/xmppframework/oKNwXOQvz5A

Thanks in advance.