mirror of
https://github.com/Andre0512/pyhOn.git
synced 2024-12-01 01:27:17 +01:00
28 lines
735 B
Python
28 lines
735 B
Python
from typing import Union, Any, TYPE_CHECKING, Protocol
|
|
|
|
import aiohttp
|
|
from yarl import URL
|
|
|
|
if TYPE_CHECKING:
|
|
from pyhon.parameter.base import HonParameter
|
|
from pyhon.parameter.enum import HonParameterEnum
|
|
from pyhon.parameter.fixed import HonParameterFixed
|
|
from pyhon.parameter.program import HonParameterProgram
|
|
from pyhon.parameter.range import HonParameterRange
|
|
|
|
|
|
class Callback(Protocol): # pylint: disable=too-few-public-methods
|
|
def __call__(
|
|
self, url: str | URL, *args: Any, **kwargs: Any
|
|
) -> aiohttp.client._RequestContextManager:
|
|
...
|
|
|
|
|
|
Parameter = Union[
|
|
"HonParameter",
|
|
"HonParameterRange",
|
|
"HonParameterEnum",
|
|
"HonParameterFixed",
|
|
"HonParameterProgram",
|
|
]
|