afscgap.typesdef

Type definitions for the afscgap project.

(c) 2023 Regents of University of California / The Eric and Wendy Schmidt Center for Data Science and the Environment at UC Berkeley.

This file is part of afscgap released under the BSD 3-Clause License. See LICENSE.md.

 1"""
 2Type definitions for the afscgap project.
 3
 4(c) 2023 Regents of University of California / The Eric and Wendy Schmidt Center
 5for Data Science and the Environment at UC Berkeley.
 6
 7This file is part of afscgap released under the BSD 3-Clause License. See
 8LICENSE.md.
 9"""
10import typing
11
12import requests
13
14
15OPT_FLOAT = typing.Optional[float]
16OPT_INT = typing.Optional[int]
17OPT_STR = typing.Optional[str]
18
19STR_OR_DICT = typing.Union[str, dict]
20RANGE_TUPLE = typing.Tuple[float]
21FLOAT_PARAM = typing.Optional[typing.Union[float, dict, RANGE_TUPLE]]
22INT_PARAM = typing.Optional[typing.Union[int, dict, RANGE_TUPLE]]
23STR_PARAM = typing.Optional[STR_OR_DICT]
24
25REQUESTOR = typing.Callable[[str], requests.Response]
26OPT_REQUESTOR = typing.Optional[REQUESTOR]
OPT_FLOAT = typing.Optional[float]
OPT_INT = typing.Optional[int]
OPT_STR = typing.Optional[str]
STR_OR_DICT = typing.Union[str, dict]
RANGE_TUPLE = typing.Tuple[float]
FLOAT_PARAM = typing.Union[float, dict, typing.Tuple[float], NoneType]
INT_PARAM = typing.Union[int, dict, typing.Tuple[float], NoneType]
STR_PARAM = typing.Union[str, dict, NoneType]
REQUESTOR = typing.Callable[[str], requests.models.Response]
OPT_REQUESTOR = typing.Optional[typing.Callable[[str], requests.models.Response]]