Package tv.phantombot.twitch.irc
Class TwitchSession
java.lang.Object
java.util.concurrent.SubmissionPublisher<Message>
tv.phantombot.twitch.irc.chat.utils.MessageQueue
tv.phantombot.twitch.irc.TwitchSession
- All Implemented Interfaces:
AutoCloseable,Flow.Processor<Message,,Message> Flow.Publisher<Message>,Flow.Subscriber<Message>
-
Field Summary
Fields inherited from class tv.phantombot.twitch.irc.chat.utils.MessageQueue
channelName, isAllowedToSend, nextReminder, REMINDER_INTERVAL, subscription -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Method that stops everything for TwitchWSIRC, there's no going back after this.voidMethod that returns the bot name.Method that returns the channel namevoidMethod that will do the moderation check of the bot.intvoidvoidvoidvoidquitIRC()voidMethod that handles reconnecting with Twitch.voidMethod that sends channel message.Methods inherited from class tv.phantombot.twitch.irc.chat.utils.MessageQueue
isAllowedToSendMessages, kill, onError, onSubscribe, say, sayNow, setAllowSendMessagesMethods inherited from class java.util.concurrent.SubmissionPublisher
closeExceptionally, consume, estimateMaximumLag, estimateMinimumDemand, getClosedException, getExecutor, getMaxBufferCapacity, getNumberOfSubscribers, getSubscribers, hasSubscribers, isClosed, isSubscribed, offer, offer, submit, subscribeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.concurrent.Flow.Publisher
subscribe
-
Constructor Details
-
TwitchSession
Class constructor.- Parameters:
channelName-botName-
-
-
Method Details
-
doSubscribe
public void doSubscribe() -
getChannelName
Method that returns the channel name- Returns:
- channelName
-
joinSuccess
public void joinSuccess() -
getBotName
Method that returns the bot name.- Returns:
- botName
-
getWrites
public int getWrites() -
send
Method that sends channel message.- Parameters:
message-
-
getModerationStatus
public void getModerationStatus()Method that will do the moderation check of the bot. -
reconnect
public void reconnect()Method that handles reconnecting with Twitch. -
onNext
-
onComplete
public void onComplete() -
quitIRC
public void quitIRC() -
close
public void close()Method that stops everything for TwitchWSIRC, there's no going back after this.- Specified by:
closein interfaceAutoCloseable- Overrides:
closein classSubmissionPublisher<Message>
-