(self, format)
| 112 | def timestamp(self): |
| 113 | return int(mktime(self.timetuple())) # Seconds elapsed since 1/1/1970. |
| 114 | def strftime(self, format): |
| 115 | if self.year < 1900: |
| 116 | # Python's strftime() doesn't handle year < 1900: |
| 117 | return strftime(format, (1900,) + self.timetuple()[1:]).replace("1900", str(self.year), 1) |
| 118 | return datetime.strftime(self, format) |
| 119 | def copy(self): |
| 120 | return date(self.timestamp) |
| 121 | def __str__(self): |