pydate
Python package made to set, parse, & format DateTime objects.
Python version 3.6 is required at a minimum.
To install the package with pip enter command in terminal:
pip install pydate
To uninstall the package with pip enter command in terminal:
pip uninstall pydate
Note: All object params are optional. Their values are set None without constructor.
Module Year
| Attribute/Method | Description |
|---|---|
year
|
Attribute of the int type representing a year. The attribute must be 4 digits. |
get_year()
|
Return the year attribute value. |
set_year(year)
|
Set the year attribute value. |
set_year_UTC()
|
Set the year attribute to the current UTC year. |
tostring()
|
Return a string representing the Year class attribute values. |
Module Date
Note: This class inherits the attributes/methods of the Year class.
| Attribute/Method | Description |
|---|---|
month
|
Attribute of the int type representing a month. The attribute's value must be between 1 & 12. |
day
|
Attribute of the int type representing a day. The attribute's value must be between 1 & 31. |
get_month()
|
Return the month attribute value. |
get_day()
|
Return the day attribute value. |
get_gregorian()
|
Return the Gregorian month name. |
get_total_days()
|
Return a dictionary denoting the total days in each month. Uses each gregorian month name as a key. |
set_month(month)
|
Set the month attribute value. |
set_month_UTC()
|
Set the month attribute to the current UTC month. |
set_day(day)
|
Set the day attribute value. |
set_day_UTC()
|
Set the day attribute to the current UTC day. |
tostring()
|
Return a string representing the Date class attribute values. |
Module Time
| Attribute/Method | Description |
|---|---|
hour
|
Attribute of the int type representing a hour. The attribute's value must be between 0 & 23. |
minute
|
Attribute of the int type representing a minute. The attribute's value must be between 0 & 59. |
second
|
Attribute of the int type representing a second. The attribute's value must be between 0 & 59. |
get_hour()
|
Return the hour attribute value. |
get_minute()
|
Return the minute attribute value. |
get_second()
|
Return the second attribute value. |
set_hour(hour)
|
Set the hour attribute value. |
set_hour_UTC()
|
Set the hour attribute to the current UTC hour. |
set_minute(minute)
|
Set the minute attribute value. |
set_minute_UTC()
|
Set the minute attribute to the current UTC minute. |
set_second(second)
|
Set the second attribute value. |
set_second_UTC()
|
Set the second attribute to the current UTC second. |
tostring()
|
Return a string representing the Time class attribute values. |
Module DateTime
Note: This class inherits the attributes/methods of both the Date & Time classes.
| Attribute/Method | Description |
|---|---|
set_UTC()
|
Set second, minute, hour, day, month, and year attribute values to current UTC values. |
set_timezone(timezone)
|
Set second, minute, hour, day, month, and year attribute values to values of timezone indicated in the argument.
The 'timezone' argument must be a string. Values for the 'timezone' argument can be the following acronyms (Not Case Sensitive): - AST => (Atlantic Standard Time UTC-04:00) - EDT => (Eastern Daylight Time UTC-04:00) - EST => (Eastern Standard Time UTC-05:00) - CDT => (Central Daylight Time UTC-05:00) - CST => (Central Standard Time UTC-06:00) - MDT => (Mountain Daylight Time UTC-06:00) - MST => (Mountain Standard Time UTC-07:00) - PDT => (Pacific Daylight Time UTC-07:00) - PST => (Pacific Standard Time UTC-08:00) - AKDT => (Alaska Daylight Time UTC-08:00) - AKST => (Alaska Standard Time UTC-09:00) - HDT => (Hawaii-Aleutian Daylight Time UTC-09:00) - HST => (Hawaii-Aleutian Standard Time UTC-10:00) - SST => (Samoa Standard Time UTC-11:00) |
tostring()
|
Return a string representing the DateTime class attribute values. |
Metadata
Release files for pydate 1.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pydate-1.2.0.tar.gz | 5.6 kB | Without provenance | Details for pydate-1.2.0.tar.gz |
Release files / pydate-1.2.0.tar.gz
| Download URL | pydate-1.2.0.tar.gz |
|---|---|
| Size | 5.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4356bf9178fae1413f1b0568a08fafb67706ea54c5556215af086a1ff4bbd0f5
|
|
BLAKE2b-256 checksum How to use checksums |
5eff681b828915ec778fd75d02afefd9faca858456e1a7ff1457fa7e6b2ce9e7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.2
|
Security for pydate 1.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.