Package com.jtelegram.api.commands
Interface CommandHandler
-
- All Superinterfaces:
CommandFilter
public interface CommandHandler extends CommandFilter
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
onCommand(TextMessageEvent event, Command command)
Runs this command.default boolean
test(TextMessageEvent event, Command command)
Checks to see if the given event and command test to betrue
according to this filter.
-
-
-
Method Detail
-
onCommand
void onCommand(TextMessageEvent event, Command command)
Runs this command.- Parameters:
event
- The event containing the commandcommand
- The command being run
-
test
default boolean test(TextMessageEvent event, Command command)
Description copied from interface:CommandFilter
Checks to see if the given event and command test to betrue
according to this filter.- Specified by:
test
in interfaceCommandFilter
- Parameters:
event
- The event to be testedcommand
- The command data executed in this event- Returns:
- True if and only if this filter allows this event and command combination to go ahead.
-
-