Home
last modified time | relevance | path

Searched refs:timedelta (Results 1 – 25 of 67) sorted by relevance

123

/external/python/cpython2/Lib/test/
Dtest_datetime.py14 from datetime import timedelta
46 offset = timedelta(minutes=offset)
48 dstoffset = timedelta(minutes=dstoffset)
95 self.assertEqual(fo.utcoffset(dt), timedelta(minutes=3))
97 self.assertEqual(fo.dst(dt), timedelta(minutes=42))
112 offset = timedelta(minutes=-300)
168 theclass = timedelta
172 td = timedelta
197 td = timedelta
242 a = timedelta(42)
[all …]
/external/python/cpython2/Doc/includes/
Dtzinfo-examples.py1 from datetime import tzinfo, timedelta, datetime
3 ZERO = timedelta(0)
4 HOUR = timedelta(hours=1)
30 self.__offset = timedelta(minutes = offset)
46 STDOFFSET = timedelta(seconds = -_time.timezone)
48 DSTOFFSET = timedelta(seconds = -_time.altzone)
87 dt += timedelta(days_to_go)
119 self.stdoffset = timedelta(hours=hours)
/external/autotest/site_utils/suite_scheduler/
Dtimed_event_unittest.py73 init_now = self.BaseTime() - datetime.timedelta(seconds=1)
74 fire_now = self.BaseTime() + datetime.timedelta(seconds=1)
105 fake_now += datetime.timedelta(days=days_to_jump, hours=hours_to_jump)
115 since_date = self.BaseTime() - datetime.timedelta(days=days)
209 new._deadline += datetime.timedelta(days=1)
218 fake_now = self.BaseTime() + datetime.timedelta(hours=0.5)
227 fake_now += datetime.timedelta(days=1) # Jump to tomorrow night.
234 return now - datetime.timedelta(minutes=1)
238 return now + datetime.timedelta(hours=0.5)
335 new._deadline += datetime.timedelta(days=7)
[all …]
Dtimed_event.py72 since_date = self._deadline - datetime.timedelta(days=days_ago)
146 deadline = now_hour + datetime.timedelta(hours=extra_hour)
152 self._deadline = self._deadline + datetime.timedelta(hours=1)
222 deadline = this_week_deadline + datetime.timedelta(days=1)
241 self._deadline = self._deadline + datetime.timedelta(days=1)
/external/python/cpython2/Doc/library/
Ddatetime.rst97 .. class:: timedelta
124 The distinction between naive and aware doesn't apply to :class:`timedelta`
130 timedelta
137 .. _datetime-timedelta:
139 :class:`timedelta` Objects
142 A :class:`timedelta` object represents a duration, the difference between two
145 .. class:: timedelta([days[, seconds[, microseconds[, milliseconds[, minutes[, hours[, weeks]]]]]]])
176 >>> from datetime import timedelta
177 >>> d = timedelta(microseconds=-1)
184 .. attribute:: timedelta.min
[all …]
/external/autotest/site_utils/
Dcount_jobs_unittest.py7 from datetime import timedelta, datetime
37 count_jobs.number_of_jobs_since(timedelta(days=999)))
54 models.Job(created_on=some_day - timedelta(hours=i)).save()
58 count_jobs.number_of_jobs_since(timedelta(days=days)))
Dcount_jobs.py10 from datetime import datetime, timedelta
38 count = number_of_jobs_since(timedelta(days=1))
Ddiagnosis_utils.py114 self.deadline = datetime.now() + datetime_base.timedelta(
157 self.timeout_hours = datetime_base.timedelta(hours=timeout_mins/60.0)
Dprodcertstatus_checker.py33 tt = datetime.timedelta(seconds=loas_expire)
/external/autotest/utils/
Dsite_check_dut_usage.py86 total_run_time = datetime.timedelta()
87 total_queued_time = datetime.timedelta()
117 print 'Average Job Time ', datetime.timedelta(seconds=int(
119 print 'Average Time Job Queued ', datetime.timedelta(seconds=int(
/external/toolchain-utils/automation/common/
Devents.py42 return datetime.timedelta(seconds=time_elapsed)
45 if isinstance(time_elapsed, datetime.timedelta):
60 return datetime.timedelta(seconds=int(self.time_elapsed.seconds))
107 return datetime.timedelta(seconds=int(total_time_elapsed))
/external/autotest/client/cros/video/
Dsequence_generator.py44 return [datetime.timedelta(milliseconds=x) for x in
83 return [datetime.timedelta(seconds=t) for t in randomized_time_seq]
Dcollect_golden_images.py71 start = datetime.timedelta(minutes=tmp.minute, seconds=tmp.second)
92 stop = datetime.timedelta(minutes=tmp.minute, seconds=tmp.second)
Dvideo_player.py115 self.seek_to(datetime.timedelta(seconds=0))
/external/toolchain-utils/crosperf/
Dexperiment_status.py74 eta = datetime.timedelta(seconds=eta_seconds)
82 datetime.timedelta(seconds=int(elapsed_time)), eta))
122 elapsed = str(datetime.timedelta(seconds=int(t - t_last)))
/external/python/cpython2/Demo/tkinter/ttk/
Dttkcalendar.py21 timedelta = calendar.datetime.timedelta variable in Calendar
192 self._date = self._date - self.timedelta(days=1)
201 self._date = self._date + self.timedelta(
/external/toolchain-utils/deprecated/
Dsheriff_rotation.py41 week_begin = day - datetime.timedelta(days=day_of_week)
42 week_end = day + datetime.timedelta(days=(6 - day_of_week))
/external/python/cpython2/Lib/unittest/test/
Dtest_assertions.py51 second = first + datetime.timedelta(seconds=10)
53 delta=datetime.timedelta(seconds=20))
55 delta=datetime.timedelta(seconds=5))
/external/libnl/python/netlink/route/
Daddress.py276 return datetime.timedelta(seconds=msecs)
290 return datetime.timedelta(seconds=msecs)
301 return datetime.timedelta(milliseconds=10*hsec)
308 return datetime.timedelta(milliseconds=10*hsec)
/external/android-clat/
Dclatd_microbenchmark.c127 double timedelta(const struct timespec tv1, const struct timespec tv2) { in timedelta() function
156 double seconds = timedelta(tv1, tv2); in benchmark()
/external/ipsec-tools/src/racoon/
Dmisc.h51 extern double timedelta __P((struct timeval *, struct timeval *));
Dmisc.c162 timedelta(t1, t2) in timedelta() function
/external/autotest/client/tests/wb_kupdate/
Dwb_kupdate_unittest.py37 _now=datetime.datetime.now() + datetime.timedelta(seconds=60)))
/external/autotest/site_utils/rpm_control_system/
Drpm_logging_config.py53 datetime.timedelta(hours=self._suspend_time_hrs)):
/external/toolchain-utils/crb/
Dcrb_driver.py148 eta = datetime.timedelta(seconds=eta_seconds)
154 datetime.timedelta(seconds=int(elapsed_time)), eta))

123