mirror of
https://github.com/koloideal/Argenta.git
synced 2026-06-10 18:15:28 +03:00
benchs
This commit is contained in:
@@ -1,10 +1,17 @@
|
||||
__all__ = ["NonStandardBehaviorHandler", "EmptyCommandHandler", "Printer", "DescriptionMessageGenerator", "HandlerFunc"]
|
||||
__all__ = [
|
||||
"NonStandardBehaviorHandler",
|
||||
"EmptyCommandHandler",
|
||||
"MostSimilarCommandGetter",
|
||||
"Printer",
|
||||
"DescriptionMessageGenerator",
|
||||
"HandlerFunc",
|
||||
]
|
||||
|
||||
from typing import Any, Protocol, TypeVar
|
||||
|
||||
from typing import Any, ParamSpec, Protocol, TypeVar
|
||||
from argenta.response import Response
|
||||
|
||||
T = TypeVar("T", contravariant=True)
|
||||
P = ParamSpec("P")
|
||||
T = TypeVar("T", contravariant=True)
|
||||
|
||||
|
||||
class NonStandardBehaviorHandler(Protocol[T]):
|
||||
@@ -22,6 +29,11 @@ class Printer(Protocol):
|
||||
raise NotImplementedError
|
||||
|
||||
|
||||
class MostSimilarCommandGetter(Protocol):
|
||||
def __call__(self, _unknown_trigger: str, /) -> str | None:
|
||||
raise NotImplementedError
|
||||
|
||||
|
||||
class DescriptionMessageGenerator(Protocol):
|
||||
def __call__(self, _command: str, _description: str, /) -> str:
|
||||
raise NotImplementedError
|
||||
|
||||
Reference in New Issue
Block a user