Package com.example.bot
Interface BotWorker
- All Known Implementing Classes:
BaseBotWorker
public interface BotWorker
The BotWorker interface defines the methods for managing bots in the chat application.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Add bots to the server with the specified parameters.void
removeBots
(int intervalExit) Remove bots from the server at a specified interval.void
startSendMessage
(int timerSendMessage, int intervalSend) Start sending messages with a specified timer and interval for sending messages.
-
Method Details
-
addBots
Add bots to the server with the specified parameters.- Parameters:
ipServer
- the IP address of the serverportServer
- the port number of the serverstartPort
- the starting port number for botscountBot
- the number of bots to addintervalCount
- the interval between adding bots
-
startSendMessage
void startSendMessage(int timerSendMessage, int intervalSend) Start sending messages with a specified timer and interval for sending messages.- Parameters:
timerSendMessage
- the timer for sending messagesintervalSend
- the interval between message sends
-
removeBots
void removeBots(int intervalExit) Remove bots from the server at a specified interval.- Parameters:
intervalExit
- the interval for removing bots
-