datetime.timedelta replacement
Project description
Installation
$ [sudo] pip install timedelta
Classes
class | __doc__ |
---|---|
timedelta.Timedelta |
datetime.timedelta replacement |
timedelta.Total |
Examples
>>> import timedelta
>>> td = timedelta.Timedelta(days=2, hours=2)
# init from datetime.timedelta
>>> td = timedelta.Timedelta(datetime1 - datetime2)
total
seconds, minutes, hours, days
>>> td = timedelta.Timedelta(days=2, hours=2)
>>> td.total.seconds
180000
>>> td.total.minutes
3000
>>> td.total.hours
50
>>> td.total.days
2
Links
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
timedelta-2019.3.24.tar.gz
(1.6 kB
view hashes)
Built Distribution
Close
Hashes for timedelta-2019.3.24-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a7705d0253575a36bf89bb3fb33c7f98c6fb6cc00c11581f1793bd2e17db6018 |
|
MD5 | 5b59437512d9ebc92b0620e10465ad36 |
|
BLAKE2b-256 | fbc51e99f437f42d5fa2d54177a7622e2c23f04a43732b7f7550415f2d256a4f |