mirror of
https://github.com/nichkara/InfinitumBotty.git
synced 2026-06-10 22:26:23 +02:00
Initalize repo
This commit is contained in:
27
FaustBot/Modules/LeaveObserverPrototype.py
Normal file
27
FaustBot/Modules/LeaveObserverPrototype.py
Normal file
@@ -0,0 +1,27 @@
|
||||
from FaustBot.Communication.Connection import Connection
|
||||
from FaustBot.Modules.ModulePrototype import ModulePrototype
|
||||
from FaustBot.Modules.ModuleType import ModuleType
|
||||
|
||||
|
||||
class LeaveObserverPrototype(ModulePrototype):
|
||||
"""
|
||||
The Prototype of a Class who can react to every action
|
||||
"""
|
||||
|
||||
@staticmethod
|
||||
def cmd():
|
||||
raise NotImplementedError()
|
||||
|
||||
@staticmethod
|
||||
def help():
|
||||
raise NotImplementedError("Need sto be implemented by subclasses!")
|
||||
|
||||
@staticmethod
|
||||
def get_module_types():
|
||||
return [ModuleType.ON_LEAVE]
|
||||
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
|
||||
def update_on_leave(self, data, connection: Connection):
|
||||
raise NotImplementedError("Some module doesn't do anything")
|
||||
Reference in New Issue
Block a user