Available on non-
Py_LIMITED_API
only.Expand description
Safe Rust wrappers for types defined in the Python datetime
library
For more details about these types, see the Python documentation
Macros§
Structs§
- PyDate
- Bindings around
datetime.date
. - PyDate
Time - Bindings for
datetime.datetime
. - PyDelta
- Bindings for
datetime.timedelta
. - PyTime
- Bindings for
datetime.time
. - PyTz
Info - Bindings for
datetime.tzinfo
.
Traits§
- PyDate
Access - Trait for accessing the date components of a struct containing a date.
- PyDelta
Access - Trait for accessing the components of a struct containing a timedelta.
- PyTime
Access - Trait for accessing the time components of a struct containing a time.
- PyTz
Info Access - Trait for accessing the components of a struct containing a tzinfo.
Functions§
- PyDate
Time_ π βCheck - Check if
op
is aPyDateTimeAPI.DateTimeType
or subtype. - PyDate_
Check π β - Check if
op
is aPyDateTimeAPI.DateType
or subtype. - PyDelta_
Check π β - Check if
op
is aPyDateTimeAPI.DetaType
or subtype. - PyTZ
Info_ π βCheck - Check if
op
is aPyDateTimeAPI.TZInfoType
or subtype. - PyTime_
Check π β - Check if
op
is aPyDateTimeAPI.TimeType
or subtype. - ensure_
datetime_ πapi - expect_
datetime_ πapi - opt_
to_ πpyobj - timezone_
from_ πoffset chrono
orjiff-02
- Equivalent to
datetime.timezone
constructor - timezone_
utc - Equivalent to
datetime.timezone.utc
- timezone_
utc_ bound Deprecated - Deprecated name for
timezone_utc
.