
type User is interface
    service
	ws_conn : dual user_comm;
end;

module newUser() return User is
-- All the user is at this point is a connection to a workstation.
-- passing along a number of random messages
-- and accepting (and then ignoring) messages to her from the 
-- workstation.
        message : VAR Data;
        generate_data : function() return Data  is
        begin
            return newData();
        end;
    parallel
        for i : integer in 1..num_messages
        do
            message := generate_data();
            ws_conn.to_workstation($message, randomAddress());
        end;
    || 
        when (?data : Data)
            ws_conn.to_user(?data)
        do
	   null;
        end;
end;
