Monday, November 08, 2010 at 12:06 AM.

system.verbs.builtins.tcp.im.builtinDrivers.jabber.code.messages.iqRosterRequest

on iqRosterRequest (connection = @system.temp.jabber.connection, idTbl = nil) {
	<<Changes
		<<5/14/02; 1:51:34 PM by JB
			<<Changelog created.
	<<iqRosterRequest requests the roster from the server; it's part of the login sequence. See http://docs.jabber.org/jpg/html/main.html#REFIQROSTER.
	
	on addAtt ( XMLadr, name, value ) {
		if not defined ( XMLadr^.["/atts"] ) {
			new ( tableType, @XMLadr^.["/atts"] )};
		XMLadr^.["/atts"].[name] = value};
	local ( result, iqTag, queryTag);
	if idTbl == nil {
		idTbl = tcp.im.builtinDrivers.jabber.code.idTables.create()};
	connection^.state = "LOGGING IN";
	new ( tableType, @result );
	bundle { // <iq type="set" id="someid">
		iqTag = xml.addTable ( @result, "iq" );
		addAtt (iqTag, "type", "set");
		idTbl^.type = "Roster Request";
		addAtt (iqTag, "id", nameOf(idTbl^) )};
	bundle { // <query xmlns="jabber:iq:roster">
		queryTag = xml.addTable(iqTag, "query" );
		addAtt (queryTag, "xmlns", "jabber:iq:roster")};
	tcp.im.builtinDrivers.jabber.code.writeXML(iqTag, connection: connection)};
iqRosterRequest(@system.temp.jabber.connection)



This listing is for code that runs in the OPML Editor environment. I created these listings because I wanted the search engines to index it, so that when I want to look up something in my codebase I don't have to use the much slower search functionality in my object database. Dave Winer.