Java Utililty Methods Second Round

List of utility methods to do Second Round

  1. HOME
  2. Java
  3. S
  4. Second Round

Description

The list of methods to do Second Round are organized into topic(s).

Method

double roundMjdToSeconds(double timeStep)
round Mjd To Seconds
double jd0 = timeStep * 100000.0;
double jd = Math.floor(jd0);
if (jd0 - jd > 0.5)
 ++jd;
timeStep = jd / 100000;
return timeStep;
long roundToNearestSecond(long time)
round To Nearest Second
return ((time + ((time >= 0) ? 500 : -500)) / 1000) * 1000;
long roundToSecond(final long pTime)
Rounds the given time down to the closest second.
return (pTime / SECOND) * SECOND;

AltStyle によって変換されたページ (->オリジナル) /