public GetUniqueRoom ( string server, string nick, RoomStateEvent callback, object state ) : void | ||
server | string | The server to send the request to |
nick | string | The nickname desired in the new room |
callback | RoomStateEvent | A callback to be called when the room is created |
state | object | State object to be passed back when the callback fires |
return | void |
public void GetUniqueRoom(string server, string nick, RoomStateEvent callback, object state)
{
if (server == null)
throw new ArgumentNullException("server");
if (nick == null)
throw new ArgumentNullException("nick");
if (callback == null)
throw new ArgumentNullException("callback");
/*
<iq from='[email protected]/desktop'
id='unique1'
to='macbeth.shakespeare.lit'
type='get'>
<unique xmlns='http://jabber.org/protocol/muc#unique'/>
</iq>
*/
UniqueIQ iq = new UniqueIQ(m_stream.Document);
iq.To = server;
BeginIQ(iq, new IqCB(GotUnique), new UniqueState(nick, callback, state));
}