Format using strftime(). The date part of the timestamp passed to underlying strftime should not be used. For a list of supported format codes, see the documentation: https://docs.python.org/3/library/datetime.html#format-codes
(self, format)
| 1659 | return cls(*time_components) |
| 1660 | |
| 1661 | def strftime(self, format): |
| 1662 | """Format using strftime(). The date part of the timestamp passed |
| 1663 | to underlying strftime should not be used. |
| 1664 | |
| 1665 | For a list of supported format codes, see the documentation: |
| 1666 | https://docs.python.org/3/library/datetime.html#format-codes |
| 1667 | """ |
| 1668 | # The year must be >= 1000 else Python's strftime implementation |
| 1669 | # can raise a bogus exception. |
| 1670 | timetuple = (1900, 1, 1, |
| 1671 | self._hour, self._minute, self._second, |
| 1672 | 0, 1, -1) |
| 1673 | return _wrap_strftime(self, format, timetuple) |
| 1674 | |
| 1675 | def __format__(self, fmt): |
| 1676 | if not isinstance(fmt, str): |
no test coverage detected