Java Milliseconds timeSinceMillis(long timestart)

Here you can find the source of timeSinceMillis(long timestart)

Description

Time elapsed since a start time.

License

Open Source License

Parameter

Parameter Description
timestart in nanoseconds

Return

milliseconds since timestart

Declaration

public static long timeSinceMillis(long timestart) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    /**/*from  w ww . j a v a2  s .c  o  m*/
     * Time elapsed since a start time.
     * @param timestart in nanoseconds
     * @return milliseconds since timestart
     */
    public static long timeSinceMillis(long timestart) {
        return (timeSince(timestart) / 1000000);
    }

    /**
     * Time elapsed since a start time.
     * @param timestart in nanoseconds
     * @return nanoseconds since timestart
     */
    public static long timeSince(long timestart) {
        return (System.nanoTime() - timestart);
    }
}

Related

  1. timeIncMillisToTimeControl(long startTimeMillis, long startIncMillis)
  2. timeMillisToString(long timeMillis)
  3. timeoutPropertyToIntMillis(long value)
  4. timeSince_MILLIS(long start_PMILLIS)
  5. timeSinceMillis(long prevTime)
  6. timeToMilliseconds(Object unit, long interval)
  7. trySleepMillis(int millis)
  8. waitMillis(long millis)
  9. waitMillis(long time)