Package tigase.mix.model
Class MixRepository<T>
java.lang.Object
tigase.mix.model.MixRepository<T>
- All Implemented Interfaces:
IMixRepository,tigase.pubsub.repository.cached.CachedPubSubRepository.NodeAffiliationProvider<T>,tigase.pubsub.repository.IItems.IListnener,tigase.pubsub.repository.IPubSubRepository.IListener
@Bean(name="mixRepository",
parent=MixComponent.class,
active=true)
public class MixRepository<T>
extends Object
implements IMixRepository, tigase.pubsub.repository.IPubSubRepository.IListener, tigase.pubsub.repository.cached.CachedPubSubRepository.NodeAffiliationProvider<T>
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidbannedParticipantFromChannel(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantJID) getAllowed(tigase.xmpp.jid.BareJID channelJID) getBanned(tigase.xmpp.jid.BareJID channelJID) getChannelConfiguration(tigase.xmpp.jid.BareJID channelJID) getChannelName(tigase.xmpp.jid.BareJID channelJID) tigase.pubsub.repository.ISubscriptionsgetNodeSubscriptions(tigase.xmpp.jid.BareJID serviceJid, String nodeName) protected IParticipantgetParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId) getParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantRealJID) getParticipantIds(tigase.xmpp.jid.BareJID channelJID) tigase.xmpp.jid.BareJIDgetParticipantJidFromJidMap(tigase.xmpp.jid.BareJID service, String participantId) tigase.xmpp.jid.JIDgetTempParticipantJID(tigase.xmpp.jid.BareJID serviceJID, String participantId) getUserAffiliations(tigase.xmpp.jid.BareJID serviceJid, tigase.xmpp.jid.BareJID jid) protected voidinvalidateChannelParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId) voiditemDeleted(tigase.xmpp.jid.BareJID serviceJID, String node, String id) voiditemWritten(tigase.xmpp.jid.BareJID serviceJID, String node, String id, String publisher, tigase.xml.Element item, String uuid) protected voidjidVisibilityChanged(tigase.xmpp.jid.BareJID serviceJID, JIDVisibility oldValue, JIDVisibility newValue) protected ChannelConfigurationloadChannelConfiguration(tigase.xmpp.jid.BareJID channelJID) tigase.pubsub.repository.cached.IAffiliationsCachednewNodeAffiliations(tigase.xmpp.jid.BareJID serviceJid, String nodeName, T nodeId, tigase.pubsub.repository.IPubSubRepository.RepositorySupplier<Map<tigase.xmpp.jid.BareJID, tigase.pubsub.repository.stateless.UsersAffiliation>> affiliationSupplier) protected voidremoveJidMap(tigase.xmpp.jid.BareJID serviceJID, List<String> participantIds) voidremoveParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId) voidremoveParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantJID) voidremoveTempParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.JID participantJID) voidserviceRemoved(tigase.xmpp.jid.BareJID userJid) protected voidupdateChannelConfiguration(tigase.xmpp.jid.BareJID serviceJID, tigase.xml.Element item) protected voidupdateJidMap(tigase.xmpp.jid.BareJID serviceJID, String participantId, tigase.xmpp.jid.BareJID realJid) protected ParticipantupdateParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId, tigase.xmpp.jid.BareJID participantJID, String nick) updateParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantJID, String nick) updateTempParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.JID participantJID, String nick) booleanvalidateItem(tigase.xmpp.jid.BareJID serviceJID, String node, String id, String publisher, tigase.xml.Element item)
-
Constructor Details
-
MixRepository
public MixRepository()
-
-
Method Details
-
getAllowed
public Optional<List<tigase.xmpp.jid.BareJID>> getAllowed(tigase.xmpp.jid.BareJID channelJID) throws tigase.component.exceptions.RepositoryException - Specified by:
getAllowedin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getBanned
public Optional<List<tigase.xmpp.jid.BareJID>> getBanned(tigase.xmpp.jid.BareJID channelJID) throws tigase.component.exceptions.RepositoryException - Specified by:
getBannedin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getParticipantIds
public List<String> getParticipantIds(tigase.xmpp.jid.BareJID channelJID) throws tigase.component.exceptions.RepositoryException - Specified by:
getParticipantIdsin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getParticipant
public IParticipant getParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantRealJID) throws tigase.component.exceptions.RepositoryException - Specified by:
getParticipantin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getParticipant
public IParticipant getParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId) throws tigase.component.exceptions.RepositoryException - Specified by:
getParticipantin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getParticipant
protected IParticipant getParticipant(MixRepository.ParticipantKey key) throws tigase.component.exceptions.RepositoryException - Throws:
tigase.component.exceptions.RepositoryException
-
removeParticipant
public void removeParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantJID) throws tigase.component.exceptions.RepositoryException - Specified by:
removeParticipantin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
removeParticipant
public void removeParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId) throws tigase.component.exceptions.RepositoryException - Specified by:
removeParticipantin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
updateParticipant
public IParticipant updateParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantJID, String nick) throws tigase.component.exceptions.RepositoryException, tigase.pubsub.exceptions.PubSubException - Specified by:
updateParticipantin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryExceptiontigase.pubsub.exceptions.PubSubException
-
updateTempParticipant
public IParticipant updateTempParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.JID participantJID, String nick) throws tigase.component.exceptions.RepositoryException, tigase.pubsub.exceptions.PubSubException - Specified by:
updateTempParticipantin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryExceptiontigase.pubsub.exceptions.PubSubException
-
updateParticipant
protected Participant updateParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId, tigase.xmpp.jid.BareJID participantJID, String nick) throws tigase.pubsub.exceptions.PubSubException, tigase.component.exceptions.RepositoryException - Throws:
tigase.pubsub.exceptions.PubSubExceptiontigase.component.exceptions.RepositoryException
-
removeTempParticipant
public void removeTempParticipant(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.JID participantJID) throws tigase.component.exceptions.RepositoryException - Specified by:
removeTempParticipantin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getTempParticipantJID
public tigase.xmpp.jid.JID getTempParticipantJID(tigase.xmpp.jid.BareJID serviceJID, String participantId) throws tigase.component.exceptions.RepositoryException - Specified by:
getTempParticipantJIDin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getChannelName
public String getChannelName(tigase.xmpp.jid.BareJID channelJID) throws tigase.component.exceptions.RepositoryException - Specified by:
getChannelNamein interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
getChannelConfiguration
public ChannelConfiguration getChannelConfiguration(tigase.xmpp.jid.BareJID channelJID) throws tigase.component.exceptions.RepositoryException - Specified by:
getChannelConfigurationin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
loadChannelConfiguration
protected ChannelConfiguration loadChannelConfiguration(tigase.xmpp.jid.BareJID channelJID) throws tigase.component.exceptions.RepositoryException - Throws:
tigase.component.exceptions.RepositoryException
-
getNodeSubscriptions
public tigase.pubsub.repository.ISubscriptions getNodeSubscriptions(tigase.xmpp.jid.BareJID serviceJid, String nodeName) throws tigase.component.exceptions.RepositoryException - Specified by:
getNodeSubscriptionsin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
serviceRemoved
public void serviceRemoved(tigase.xmpp.jid.BareJID userJid) - Specified by:
serviceRemovedin interfacetigase.pubsub.repository.IPubSubRepository.IListener
-
itemDeleted
- Specified by:
itemDeletedin interfacetigase.pubsub.repository.IItems.IListnener
-
itemWritten
public void itemWritten(tigase.xmpp.jid.BareJID serviceJID, String node, String id, String publisher, tigase.xml.Element item, String uuid) - Specified by:
itemWrittenin interfacetigase.pubsub.repository.IItems.IListnener
-
validateItem
public boolean validateItem(tigase.xmpp.jid.BareJID serviceJID, String node, String id, String publisher, tigase.xml.Element item) throws tigase.pubsub.exceptions.PubSubException - Specified by:
validateItemin interfacetigase.pubsub.repository.IItems.IListnener- Throws:
tigase.pubsub.exceptions.PubSubException
-
getUserAffiliations
public Map<String,tigase.pubsub.repository.stateless.UsersAffiliation> getUserAffiliations(tigase.xmpp.jid.BareJID serviceJid, tigase.xmpp.jid.BareJID jid) throws tigase.component.exceptions.RepositoryException - Specified by:
getUserAffiliationsin interfacetigase.pubsub.repository.cached.CachedPubSubRepository.NodeAffiliationProvider<T>- Throws:
tigase.component.exceptions.RepositoryException
-
newNodeAffiliations
public tigase.pubsub.repository.cached.IAffiliationsCached newNodeAffiliations(tigase.xmpp.jid.BareJID serviceJid, String nodeName, T nodeId, tigase.pubsub.repository.IPubSubRepository.RepositorySupplier<Map<tigase.xmpp.jid.BareJID, tigase.pubsub.repository.stateless.UsersAffiliation>> affiliationSupplier) throws tigase.component.exceptions.RepositoryException- Specified by:
newNodeAffiliationsin interfacetigase.pubsub.repository.cached.CachedPubSubRepository.NodeAffiliationProvider<T>- Throws:
tigase.component.exceptions.RepositoryException
-
bannedParticipantFromChannel
protected void bannedParticipantFromChannel(tigase.xmpp.jid.BareJID channelJID, tigase.xmpp.jid.BareJID participantJID) throws tigase.component.exceptions.RepositoryException - Throws:
tigase.component.exceptions.RepositoryException
-
invalidateChannelParticipant
protected void invalidateChannelParticipant(tigase.xmpp.jid.BareJID channelJID, String participantId) throws tigase.component.exceptions.RepositoryException - Throws:
tigase.component.exceptions.RepositoryException
-
updateChannelConfiguration
protected void updateChannelConfiguration(tigase.xmpp.jid.BareJID serviceJID, tigase.xml.Element item) -
jidVisibilityChanged
protected void jidVisibilityChanged(tigase.xmpp.jid.BareJID serviceJID, JIDVisibility oldValue, JIDVisibility newValue) throws tigase.component.exceptions.RepositoryException, tigase.pubsub.exceptions.PubSubException - Throws:
tigase.component.exceptions.RepositoryExceptiontigase.pubsub.exceptions.PubSubException
-
getParticipantJidFromJidMap
public tigase.xmpp.jid.BareJID getParticipantJidFromJidMap(tigase.xmpp.jid.BareJID service, String participantId) throws tigase.component.exceptions.RepositoryException - Specified by:
getParticipantJidFromJidMapin interfaceIMixRepository- Throws:
tigase.component.exceptions.RepositoryException
-
updateJidMap
protected void updateJidMap(tigase.xmpp.jid.BareJID serviceJID, String participantId, tigase.xmpp.jid.BareJID realJid) throws tigase.pubsub.exceptions.PubSubException, tigase.component.exceptions.RepositoryException - Throws:
tigase.pubsub.exceptions.PubSubExceptiontigase.component.exceptions.RepositoryException
-
removeJidMap
protected void removeJidMap(tigase.xmpp.jid.BareJID serviceJID, List<String> participantIds) throws tigase.component.exceptions.RepositoryException - Throws:
tigase.component.exceptions.RepositoryException
-