mirror of
https://github.com/pocketpy/pocketpy
synced 2025-10-20 11:30:18 +00:00
Create datetime.md
This commit is contained in:
parent
974cfebbb6
commit
34f3845c9f
81
docs/modules/datetime.md
Normal file
81
docs/modules/datetime.md
Normal file
@ -0,0 +1,81 @@
|
|||||||
|
---
|
||||||
|
icon: package
|
||||||
|
label: datetime
|
||||||
|
---
|
||||||
|
|
||||||
|
!!!
|
||||||
|
This module is not available now.
|
||||||
|
!!!
|
||||||
|
|
||||||
|
```python
|
||||||
|
'''
|
||||||
|
object
|
||||||
|
timedelta
|
||||||
|
timezone
|
||||||
|
date
|
||||||
|
datetime
|
||||||
|
'''
|
||||||
|
|
||||||
|
class date:
|
||||||
|
@staticmethod
|
||||||
|
def today() -> 'date': ...
|
||||||
|
|
||||||
|
def __init__(self, year, month=None, day=None): ...
|
||||||
|
|
||||||
|
@property
|
||||||
|
def year(self) -> int: ...
|
||||||
|
@property
|
||||||
|
def month(self) -> int: ...
|
||||||
|
@property
|
||||||
|
def day(self) -> int: ...
|
||||||
|
|
||||||
|
def __repr__(self) -> str: ...
|
||||||
|
|
||||||
|
def __eq__(self, other: 'date') -> bool: ...
|
||||||
|
def __lt__(self, other: 'date') -> bool: ...
|
||||||
|
def __le__(self, other: 'date') -> bool: ...
|
||||||
|
def __gt__(self, other: 'date') -> bool: ...
|
||||||
|
def __ge__(self, other: 'date') -> bool: ...
|
||||||
|
|
||||||
|
def __add__(self, other: 'timedelta') -> 'date': ...
|
||||||
|
def __sub__(self, other: 'timedelta') -> 'date': ...
|
||||||
|
|
||||||
|
class datetime(date):
|
||||||
|
@staticmethod
|
||||||
|
def now() -> 'datetime': ...
|
||||||
|
|
||||||
|
def __init__(self, year, month=None, day=None, hour=None, minute=None, second=None, tzinfo=None): ...
|
||||||
|
|
||||||
|
@property
|
||||||
|
def hour(self) -> int: ...
|
||||||
|
@property
|
||||||
|
def minute(self) -> int: ...
|
||||||
|
@property
|
||||||
|
def second(self) -> int: ...
|
||||||
|
@property
|
||||||
|
def tzinfo(self) -> 'timezone': ...
|
||||||
|
|
||||||
|
def __repr__(self) -> str: ...
|
||||||
|
|
||||||
|
def __eq__(self, other) -> bool: ...
|
||||||
|
def __lt__(self, other) -> bool: ...
|
||||||
|
def __le__(self, other) -> bool: ...
|
||||||
|
def __gt__(self, other) -> bool: ...
|
||||||
|
def __ge__(self, other) -> bool: ...
|
||||||
|
|
||||||
|
def __add__(self, other: 'timedelta') -> 'datetime': ...
|
||||||
|
def __sub__(self, other: 'timedelta') -> 'datetime': ...
|
||||||
|
|
||||||
|
def timestamp(self) -> float: ...
|
||||||
|
|
||||||
|
class timedelta:
|
||||||
|
def __init__(days, seconds): ...
|
||||||
|
|
||||||
|
def __repr__(self) -> str: ...
|
||||||
|
|
||||||
|
def __eq__(self, other: 'timedelta') -> bool: ...
|
||||||
|
def __lt__(self, other: 'timedelta') -> bool: ...
|
||||||
|
def __le__(self, other: 'timedelta') -> bool: ...
|
||||||
|
def __gt__(self, other: 'timedelta') -> bool: ...
|
||||||
|
def __ge__(self, other: 'timedelta') -> bool: ...
|
||||||
|
```
|
Loading…
x
Reference in New Issue
Block a user