MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / combine

Method combine

tools/python-3.11.9-amd64/Lib/datetime.py:1810–1820  ·  view source on GitHub ↗

Construct a datetime from a given date and a given time.

(cls, date, time, tzinfo=True)

Source from the content-addressed store, hash-verified

1808
1809 @classmethod
1810 def combine(cls, date, time, tzinfo=True):
1811 "Construct a datetime from a given date and a given time."
1812 if not isinstance(date, _date_class):
1813 raise TypeError("date argument must be a date instance")
1814 if not isinstance(time, _time_class):
1815 raise TypeError("time argument must be a time instance")
1816 if tzinfo is True:
1817 tzinfo = time.tzinfo
1818 return cls(date.year, date.month, date.day,
1819 time.hour, time.minute, time.second, time.microsecond,
1820 tzinfo, fold=time.fold)
1821
1822 @classmethod
1823 def fromisoformat(cls, date_string):

Callers 1

__add__Method · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected