hydro.flags¶
A Collection of Flag Schemes.
Classes¶
Base class for protocol classes. |
|
Enum where members are also (and must be) ints |
|
Enum representing a WHP Bottle flag. |
|
Enum where members are also (and must be) ints |
|
Enum where members are also (and must be) ints |
Module Contents¶
- class hydro.flags.FlagDefProtocol[source]¶
Bases:
ProtocolBase class for protocol classes.
Protocol classes are defined as:
class Proto(Protocol): def meth(self) -> int: ...
Such classes are primarily used with static type checkers that recognize structural subtyping (static duck-typing).
For example:
class C: def meth(self) -> int: return 0 def func(x: Proto) -> int: return x.meth() func(C()) # Passes static type check
See PEP 544 for details. Protocol classes decorated with @typing.runtime_checkable act as simple-minded runtime protocols that check only the presence of given attributes, ignoring their type signatures. Protocol classes can be generic, they are defined as:
class GenProto[T](Protocol): def meth(self) -> T: ...
- class hydro.flags.ExchangeFlag(flag)[source]¶
Bases:
enum.IntEnumEnum where members are also (and must be) ints
- Parameters:
flag (int)
- class hydro.flags.ExchangeBottleFlag(flag)[source]¶
Bases:
ExchangeFlagEnum representing a WHP Bottle flag.
This flag represents information about the sampling device itself (i.e. the niskin bottle). It should only be used for “BTLNBR_FLAG_W” values and should never be used with CTD files.
- Parameters:
flag (int)
- class hydro.flags.ExchangeSampleFlag(flag)[source]¶
Bases:
ExchangeFlagEnum where members are also (and must be) ints
- Parameters:
flag (int)
- class hydro.flags.ExchangeCTDFlag(flag)[source]¶
Bases:
ExchangeFlagEnum where members are also (and must be) ints
- Parameters:
flag (int)