Home
last modified time | relevance | path

Searched refs:fromordinal (Results 1 – 5 of 5) sorted by relevance

/third_party/python/Lib/
D_strptime.py538 datetime_result = datetime_date.fromordinal(
Ddatetime.py839 def fromordinal(cls, n): member in date
1039 return type(self).fromordinal(o)
2082 return type(self).combine(date.fromordinal(delta.days),
/third_party/python/Lib/test/
Ddatetimetester.py1124 fromord = self.theclass.fromordinal(n)
1140 d2 = self.theclass.fromordinal(n)
1144 d = self.theclass.fromordinal(n-1)
1159 self.assertEqual(d, self.theclass.fromordinal(n))
1166 b = a.fromordinal(aord)
1169 self.assertRaises(ValueError, lambda: a.fromordinal(aord - 1))
1173 self.assertEqual(b, self.theclass.fromordinal(aord + 1))
1178 b = a.fromordinal(aord)
1181 self.assertRaises(ValueError, lambda: a.fromordinal(aord + 1))
1185 self.assertEqual(b, self.theclass.fromordinal(aord - 1))
/third_party/python/Doc/library/
Ddatetime.rst511 .. classmethod:: date.fromordinal(ordinal)
518 ``date.fromordinal(d.toordinal()) == d``.
658 ``date.fromordinal(d.toordinal()) == d``.
773 >>> d = date.fromordinal(730920) # 730920th day after 1. 1. 0001
963 .. classmethod:: datetime.fromordinal(ordinal)
/third_party/python/Doc/whatsnew/
D3.7.rst1837 :meth:`date.fromordinal` and :meth:`date.fromtimestamp` are now up to