Package tv.phantombot.panel
Class WsAlertsPollsHandler
java.lang.Object
tv.phantombot.panel.WsAlertsPollsHandler
- All Implemented Interfaces:
WsFrameHandler
- Author:
- gmt2001
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidalertImage(String imageInfo) voidalertImage(String imageInfo, boolean ignoreIsPlaying) booleanGets theWsAuthenticationHandlerassigned to this endpointvoidhandleFrame(ChannelHandlerContext ctx, WebSocketFrame frame) Handles the WebSocket frame and sends a response back to the client, if necessary Only gets called if theWsAuthenticationHandlerreturnedtrueinthashCode()voidvoidvoidvoidregister()Registers thisWsFrameHandlerwith theWebSocketFrameHandlervoidsendJSONToAll(String jsonString) voidSends a macro to be played by the alerts overlayvoidvoidvoidtriggerAudioPanel(String audioHook) voidtriggerAudioPanel(String audioHook, boolean ignoreIsPlaying) voidtriggerAudioPanel(String audioHook, float volume) voidtriggerAudioPanel(String audioHook, float volume, boolean ignoreIsPlaying) voidtriggerEmote(String image) voidtriggerEmote(String image, int amount) voidtriggerEmote(String emoteId, int amount, String provider) voidtriggerEmote(String emoteId, int amount, String provider, boolean ignoreSleep) voidtriggerEmote(String image, String provider) voidtriggerEmoteAnimation(String emoteId, int amount, String provider, String animationName, int duration, boolean ignoreSleep) voidtriggerEmotes(String emoteString) Takes a string to parse and trigger one or more emotes.voidtriggerEmotes(String[] emotes, String provider)
-
Constructor Details
-
WsAlertsPollsHandler
-
-
Method Details
-
register
Description copied from interface:WsFrameHandlerRegisters thisWsFrameHandlerwith theWebSocketFrameHandler- Specified by:
registerin interfaceWsFrameHandler- Returns:
-
getAuthHandler
Description copied from interface:WsFrameHandlerGets theWsAuthenticationHandlerassigned to this endpoint- Specified by:
getAuthHandlerin interfaceWsFrameHandler- Returns:
- An
WsAuthenticationHandler
-
handleFrame
Description copied from interface:WsFrameHandlerHandles the WebSocket frame and sends a response back to the client, if necessary Only gets called if theWsAuthenticationHandlerreturnedtrue- Specified by:
handleFramein interfaceWsFrameHandler- Parameters:
ctx- TheChannelHandlerContextof the sessionframe- TheWebSocketFrameto process
-
sendJSONToAll
-
triggerAudioPanel
-
triggerAudioPanel
-
triggerAudioPanel
-
triggerAudioPanel
-
stopMedia
public void stopMedia() -
stopMedia
-
alertImage
-
alertImage
-
playVideo
-
playVideo
-
playVideo
-
playVideo
-
triggerEmotes
Takes a string to parse and trigger one or more emotes. Each emote entry is separated by a '/'. An emote describes its occurrences in the (here not relevant) string in simple start-stop notation. Multiple occurrences are separated by a comma.This is the default method that handles Twitch style emotes and uses the default emote provider Twitch
- Parameters:
emoteString- a string in format of Twitch's emote format e.g. "425618:0-2,4-6,8-10/145315:12-24"
-
triggerEmotes
-
triggerEmote
-
triggerEmote
-
triggerEmote
-
triggerEmote
-
triggerEmote
-
triggerEmoteAnimation
-
sendMacro
Sends a macro to be played by the alerts overlay- Parameters:
macroJson- A json string with commands
-
hashCode
public int hashCode() -
equals
-