public abstract class AbstractClusteredRoomStrategy extends AbstractStrategy implements StrategyIfc, InMemoryMucRepositoryClustered.RoomListener, tigase.muc.Room.RoomListener
| Modifier and Type | Field and Description |
|---|---|
protected ConcurrentHashMap<tigase.xmpp.BareJID,ConcurrentMap<tigase.xmpp.JID,ConcurrentMap<tigase.xmpp.BareJID,String>>> |
occupantsPerNode |
cl_controller, connectedNodes, localNodeJid, muc, mucRepository, REQUEST_SYNC_CMD| Constructor and Description |
|---|
AbstractClusteredRoomStrategy() |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
addOccupant(tigase.xmpp.BareJID node,
tigase.xmpp.BareJID roomJid,
tigase.xmpp.JID occupantJid,
String nickname) |
tigase.xmpp.BareJID |
getNodeForJID(tigase.xmpp.JID jid) |
void |
nodeDisconnected(tigase.xmpp.JID nodeJid)
Method called when node was disconnected
|
void |
onChangeSubject(tigase.muc.Room room,
String nick,
String newSubject,
Date changeDate) |
void |
onMessageToOccupants(tigase.muc.Room room,
tigase.xmpp.JID from,
tigase.xml.Element[] contents) |
void |
onRoomCreated(tigase.muc.Room room) |
void |
onRoomDestroyed(tigase.muc.Room room,
tigase.xml.Element destroyElement) |
void |
onSetAffiliation(tigase.muc.Room room,
tigase.xmpp.BareJID jid,
tigase.muc.Affiliation newAffiliation) |
boolean |
processPacket(tigase.server.Packet packet)
Method called when packet is received by component to preprocess packet
before/instead of passing it back to non clustered component
|
protected boolean |
removeOccupant(tigase.xmpp.BareJID node,
tigase.xmpp.BareJID roomJid,
tigase.xmpp.JID occupantJid) |
void |
setClusterController(tigase.cluster.api.ClusterControllerIfc cl_controller)
Setter used to set instance of cluster controller
|
void |
setMucRepository(InMemoryMucRepositoryClustered mucRepository)
Setter to pass instance of InMemoryMucRepositoryClustered
|
void |
start()
Method called when component is started
|
void |
stop()
Method called when component is stopped
|
forwardPacketToNode, getAllNodes, nodeConnected, onOccupantAdded, onOccupantRemoved, requestSync, sendRemoteOccupantRemovalOnDisconnect, sendRemovalFromRoomOnNodeDisconnect, setLocalNodeJid, setMucComponentClusteredclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAllNodes, nodeConnected, setMucComponentClusteredprotected final ConcurrentHashMap<tigase.xmpp.BareJID,ConcurrentMap<tigase.xmpp.JID,ConcurrentMap<tigase.xmpp.BareJID,String>>> occupantsPerNode
public void nodeDisconnected(tigase.xmpp.JID nodeJid)
StrategyIfcnodeDisconnected in interface StrategyIfcnodeDisconnected in class AbstractStrategypublic boolean processPacket(tigase.server.Packet packet)
StrategyIfcprocessPacket in interface StrategyIfcpublic void setMucRepository(InMemoryMucRepositoryClustered mucRepository)
StrategyIfcsetMucRepository in interface StrategyIfcsetMucRepository in class AbstractStrategypublic void start()
StrategyIfcstart in interface StrategyIfcpublic void stop()
StrategyIfcstop in interface StrategyIfcpublic void setClusterController(tigase.cluster.api.ClusterControllerIfc cl_controller)
StrategyIfcsetClusterController in interface StrategyIfcsetClusterController in class AbstractStrategypublic void onRoomCreated(tigase.muc.Room room)
onRoomCreated in interface InMemoryMucRepositoryClustered.RoomListenerpublic void onRoomDestroyed(tigase.muc.Room room,
tigase.xml.Element destroyElement)
onRoomDestroyed in interface InMemoryMucRepositoryClustered.RoomListenerpublic void onChangeSubject(tigase.muc.Room room,
String nick,
String newSubject,
Date changeDate)
onChangeSubject in interface tigase.muc.Room.RoomListenerpublic void onSetAffiliation(tigase.muc.Room room,
tigase.xmpp.BareJID jid,
tigase.muc.Affiliation newAffiliation)
onSetAffiliation in interface tigase.muc.Room.RoomListenerpublic void onMessageToOccupants(tigase.muc.Room room,
tigase.xmpp.JID from,
tigase.xml.Element[] contents)
onMessageToOccupants in interface tigase.muc.Room.RoomListenerprotected boolean addOccupant(tigase.xmpp.BareJID node,
tigase.xmpp.BareJID roomJid,
tigase.xmpp.JID occupantJid,
String nickname)
addOccupant in class AbstractStrategyprotected boolean removeOccupant(tigase.xmpp.BareJID node,
tigase.xmpp.BareJID roomJid,
tigase.xmpp.JID occupantJid)
removeOccupant in class AbstractStrategypublic tigase.xmpp.BareJID getNodeForJID(tigase.xmpp.JID jid)
Copyright © 2015 Tigase. All rights reserved.