anyconfig.ioinfo.datatypes¶
anyconfig basic data types.
- class anyconfig.ioinfo.datatypes.IOInfo(src: pathlib.Path | IO, type: str, path: str, extension: str)¶
Bases:
NamedTupleEquivalent to collections.namedtuple.
- src: Path | IO¶
Alias for field number 0
- type: str¶
Alias for field number 1
- path: str¶
Alias for field number 2
- extension: str¶
Alias for field number 3
- __annotations__ = {'extension': ForwardRef('str'), 'path': ForwardRef('str'), 'src': ForwardRef('pathlib.Path | typing.IO'), 'type': ForwardRef('str')}¶
- __getnewargs__()¶
Return self as a plain tuple. Used by copy and pickle.
- __match_args__ = ('src', 'type', 'path', 'extension')¶
- __module__ = 'anyconfig.ioinfo.datatypes'¶
- __orig_bases__ = (<function NamedTuple>,)¶
- __repr__()¶
Return a nicely formatted representation string
- __slots__ = ()¶
- _asdict()¶
Return a new dict which maps field names to their values.
- _field_defaults = {}¶
- _fields = ('src', 'type', 'path', 'extension')¶
- classmethod _make(iterable)¶
Make a new IOInfo object from a sequence or iterable
- _replace(**kwds)¶
Return a new IOInfo object replacing specified fields with new values