Using the startingTime as the relative starting point, sleep this thread
until the next timestamp would occur.

@param startingTime the relative starting time in milliseconds
@param timestamp the timestamp to wait for in milliseconds since the
epoch
545347
private void waitForNextRecord(long startingTime, long timestamp) {
        if(mFirstTimestamp == 0) {
            mFirstTimestamp = timestamp;
            Log.d(TAG, "Storing " + timestamp + " as the first " +
                    "timestamp of the trace file");
        }
        long targetTime = startingTime + (timestamp - mFirstTimestamp);
        long sleepDuration = Math.max(targetTime - System.currentTimeMillis(), 0);
        try {
            Thread.sleep(sleepDuration);
        } catch(InterruptedException e) {}
    }
674798
private void start(long time, String name){
		name = getName(name);
		TimerGroupItem timer = m_timers.get(name);
		if (timer == null){
			timer = new TimerGroupItem(name);
			m_timers.put(name, timer);
		}
		timer.start(time);
		m_total.start(time);
	}
662671
@Override
    public synchronized void start() {
        if (!started.getAndSet(true)) {
            finished.set(false);
            thread.start();
        }
    }
1306942
def start_time
      @start_time ||= @events.select { |event|
        event.is_a?(RequestWillBeSent)
      }.select { |event|
        event.request['url'] == @url
      }.map { |event|
        event.timestamp
      }.first
    end
891459
private void startConferenceTimer() {
        final long conferenceTotalLifeInMillis = RestcommConfiguration.getInstance().getMain().getConferenceTimeout()*1000;
        final long conferenceRemainingLife =  conferenceTotalLifeInMillis - conferenceAge();
        context().setReceiveTimeout(Duration.create(conferenceRemainingLife, TimeUnit.MILLISECONDS));
        if(logger.isInfoEnabled())
            logger.info(String.format("conference timer started for: %s milliseconds", conferenceRemainingLife));
    }
883857
public void setTimeStamp(final String timeStamp)
	{

		String time = timeStamp.replace('T', ' ');
		time = time.replace('Z', ' ');

		this.timeStamp = Timestamp.valueOf(time);
	}
828527
@Override
  public void setEndTime(Date endTime) {

    Date sTime = getStartTime();
    if (sTime != null && endTime != null && sTime.after(endTime)) {
      throw new IllegalArgumentException("End time cannot be before start time");
    }

    this.endTime = endTime;
  }
142982
public void setStartDate(String startDate) {
        if (StringUtils.isNotBlank(startDate)) {
            this.startDate = Instant.parse(startDate);
        }
    }
810603
@Override
    public void begin() throws NotSupportedException, SystemException
    {
        if (log.isDebugEnabled())
            log.info("beginning JTA transaction");

        Transaction tx = threadLocal.get();
        if (tx != null)
        {
            if ((tx.getStatus() == Status.STATUS_MARKED_ROLLBACK))
            {
                throw new NotSupportedException("Nested Transaction not supported!");
            }
        }

        Integer timer = timerThead.get();
        threadLocal.set(new KunderaTransaction(timer != null ? timer : DEFAULT_TIME_OUT));
    }
412913
@Override
    public ScheduledFuture<?> schedule(Runnable task, Date startTime) {
        ScheduledExecutorService executor = getScheduledExecutor();
        long initialDelay = startTime.getTime() - System.currentTimeMillis();
        try {
            return executor.schedule(errorHandlingTask(task, false), initialDelay, TimeUnit.MILLISECONDS);
        } catch (RejectedExecutionException ex) {
            throw new TaskRejectedException("Executor [" + executor + "] did not accept task: " + task, ex);
        }
    }
1036063
public static void start(String name) {
    if (!active) return;

    TimerNode root = new TimerNode(name, System.currentTimeMillis());
    TimerStack stack = (TimerStack) curStack.get();
    if (null == stack) curStack.set(new TimerStack(root));
    else stack.push(root);
  }
414565
public void scheduleAt(final org.easybatch.core.job.Job job, final Date startTime) throws JobSchedulerException {
        checkNotNull(job, "job");
        checkNotNull(startTime, "startTime");

        String name = job.getName();
        String jobName = JOB_NAME_PREFIX + name;
        String triggerName = TRIGGER_NAME_PREFIX + name;

        Trigger trigger = newTrigger()
                .withIdentity(triggerName)
                .startAt(startTime)
                .forJob(jobName)
                .build();

        JobDetail jobDetail = getJobDetail(job, jobName);

        try {
            LOGGER.info("Scheduling job ''{}'' to start at {}", name, startTime);
            scheduler.scheduleJob(jobDetail, trigger);
        } catch (SchedulerException e) {
            throw new JobSchedulerException(format("Unable to schedule job '%s'", name), e);
        }
    }
988378
public void start(long period, TimeUnit unit) {
		synchronized (this) {
			if (started) {
				throw new IllegalStateException("This reporter has already been started");
			}
			final long periodInMS = unit.toMillis(period);
			executor.scheduleAtFixedRate(new Runnable() {
				@Override
				public void run() {
					try {
						report();
					} catch (RuntimeException ex) {
						logger.error("RuntimeException thrown from {}#report. Exception was suppressed.", ScheduledMetrics2Reporter.this.getClass().getSimpleName(), ex);
					}
				}
			}, getOffsetUntilTimestampIsDivisableByPeriod(clock.getTime(), periodInMS), periodInMS, TimeUnit.MILLISECONDS);
			this.clock = new QuantizedClock(clock, periodInMS);
			this.started = true;
		}
	}
687297
def set_beginTimestamp(self,btimestamp=None):
        
        if btimestamp is None:
            import time
            btimestamp = time.strftime('%Y-%m-%dT%H:%M:%S%Z')
        self.node.set('beginTimestamp',btimestamp)
919464
public void setTimeRange(String fieldName, Date startTime, Date endTime) {
		this.where += " and " + fieldName + ">=? and " + fieldName + "<=?";
		this.getParam().setDate(startTime);
		this.getParam().setDate(endTime);
	}
393701
public final void setInterval(LocalTime startTime, LocalTime endTime) {
        setInterval(startTime, endTime, ZoneId.systemDefault());
    }
725100
public void start(String name) {
        stopLastTimeInstrument();
        StopWatch childSW = new StopWatch(name);
        childTimeInstrumentList.add(childSW);
    }