Class PubSubAuthRevokeEvent
java.lang.Object
com.github.philippheuer.events4j.core.domain.Event
com.github.twitch4j.common.events.TwitchEvent
com.github.twitch4j.pubsub.events.PubSubAuthRevokeEvent
- All Implemented Interfaces:
com.github.philippheuer.events4j.api.domain.IEvent
Fired when a user access token had outstanding PubSub subscriptions, but was revoked.
An authorization can be revoked at any time for a number of reasons, such a user disconnecting from an app through Connections Settings.
Topics associated with the authorization will automatically be unlistened to.
-
Constructor Summary
ConstructorsConstructorDescriptionPubSubAuthRevokeEvent(ITwitchPubSub socket, @NotNull Map<@NotNull String, @Nullable PubSubRequest> revokedListensByTopic) Creates a newPubSubAuthRevokeEventinstance. -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleanMappings of revoked topic names to the associatedPubSubRequest(LISTEN).The PubSub websocket that was subscribed to these revoked topics.inthashCode()toString()Methods inherited from class com.github.philippheuer.events4j.core.domain.Event
getEventId, getFiredAt, getFiredAtInstant, getServiceMediator, setEventId, setFiredAt, setFiredAtInstant, setServiceMediator
-
Constructor Details
-
PubSubAuthRevokeEvent
public PubSubAuthRevokeEvent(ITwitchPubSub socket, @NotNull @NotNull Map<@NotNull String, @Nullable PubSubRequest> revokedListensByTopic) Creates a newPubSubAuthRevokeEventinstance.- Parameters:
socket- The PubSub websocket that was subscribed to these revoked topics.revokedListensByTopic- Mappings of revoked topic names to the associatedPubSubRequest(LISTEN).Warning: Values can be null if you manually call
ITwitchPubSub.listenOnTopic(PubSubRequest)orITwitchPubSub.listenOnTopic(PubSubType, OAuth2Credential, Collection)with requests that contain more than one topic in a singlePubSubType.LISTEN.
-
-
Method Details
-
getTopicNames
- Returns:
- the topics that were revoked (including the user id's)
-
getSocket
The PubSub websocket that was subscribed to these revoked topics. -
getRevokedListensByTopic
Mappings of revoked topic names to the associatedPubSubRequest(LISTEN).Warning: Values can be null if you manually call
ITwitchPubSub.listenOnTopic(PubSubRequest)orITwitchPubSub.listenOnTopic(PubSubType, OAuth2Credential, Collection)with requests that contain more than one topic in a singlePubSubType.LISTEN. -
toString
- Overrides:
toStringin classTwitchEvent
-
equals
- Overrides:
equalsin classTwitchEvent
-
canEqual
- Overrides:
canEqualin classTwitchEvent
-
hashCode
public int hashCode()- Overrides:
hashCodein classTwitchEvent
-