Commit cf8a124e authored by Alex Mateescu's avatar Alex Mateescu Committed by alexm

OF-700 Added a single method to MUC service. The implementation simply removes...

OF-700 Added a single method to MUC service. The implementation simply removes a room from cache and reads it again.

git-svn-id: http://svn.igniterealtime.org/svn/repos/openfire/trunk@13747 b35dd754-fafc-0310-a699-88a17e54d16e
parent 1e3721ec
......@@ -228,7 +228,14 @@ public interface MultiUserChatService extends Component {
* @return The chatroom for the given name or null if the room does not exists.
*/
MUCRoom getChatRoom(String roomName);
/**
* Forces a re-read of the room. Useful when a change occurs externally.
*
* @param roomName Name of the room to refresh.
*/
void refreshChatRoom(String roomName);
/**
* Retuns a list with a snapshot of all the rooms in the server (i.e. persistent or not,
* in memory or not).
......
......@@ -598,6 +598,11 @@ public class MultiUserChatServiceImpl implements Component, MultiUserChatService
return room;
}
public void refreshChatRoom(String roomName) {
rooms.remove(roomName);
getChatRoom(roomName);
}
public LocalMUCRoom getLocalChatRoom(String roomName) {
return rooms.get(roomName);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment