diff options
author | Sven Göthel <[email protected]> | 2024-02-02 08:15:26 +0100 |
---|---|---|
committer | Sven Göthel <[email protected]> | 2024-02-02 08:15:26 +0100 |
commit | a67d19d005de669c0c4b240745d5359921acc90a (patch) | |
tree | f960d94a46d565916f4f72966417e630be6e80c3 | |
parent | af281cc88434f5cf6cdaeaf7fe379ba7f9e6d978 (diff) |
PTS: Rename millisToTimeStr() -> toTimeStr(), analogue to toMillis()
-rw-r--r-- | src/java/com/jogamp/common/av/PTS.java | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/java/com/jogamp/common/av/PTS.java b/src/java/com/jogamp/common/av/PTS.java index 2b1e1e0..32fca02 100644 --- a/src/java/com/jogamp/common/av/PTS.java +++ b/src/java/com/jogamp/common/av/PTS.java @@ -89,15 +89,15 @@ public final class PTS { /** Returns the System Clock Reference (SCR) in milliseconds of last PTS update via {@link #set(long, int)}. */ public long getSCR() { return scr; } - /** Returns {@link #getSCR()} as time string representation via {@link #millisToTimeStr(long, boolean)}. */ + /** Returns {@link #getSCR()} as time string representation via {@link #toTimeStr(long, boolean)}. */ public String getSCRTimeStr(final boolean addFractions) { - return millisToTimeStr(getSCR(), addFractions); + return toTimeStr(getSCR(), addFractions); } /** Returns the last updated PTS value via {@link #set(long, int)} w/o System Clock Reference (SCR) interpolation. */ public int getLast() { return pts; } - /** Returns {@link #getLast()} as time string representation via {@link #millisToTimeStr(long, boolean)}. */ + /** Returns {@link #getLast()} as time string representation via {@link #toTimeStr(long, boolean)}. */ public String getLastTimeStr(final boolean addFractions) { - return millisToTimeStr(getLast(), addFractions); + return toTimeStr(getLast(), addFractions); } /** Returns the external playback speed. */ @@ -141,9 +141,9 @@ public final class PTS { /** Returns {@link #get(long)} passing {@link Clock#currentMillis()}. */ public int getCurrent() { return get( Clock.currentMillis() ); } - /** Returns {@link #get(long)} as time string representation via {@link #millisToTimeStr(long, boolean)}. */ + /** Returns {@link #get(long)} as time string representation via {@link #toTimeStr(long, boolean)}. */ public String getTimeStr(final long currentMillis, final boolean addFractions) { - return millisToTimeStr(get(currentMillis), addFractions); + return toTimeStr(get(currentMillis), addFractions); } /** Returns {@link #getLast()} - rhs.{@link #getLast()}. */ @@ -165,9 +165,9 @@ public final class PTS { * Returns a time string representation '[HH:]mm:ss[.SSS]', dropping unused hour quantities and fractions of seconds optionally. * @param millis complete time in milliseconds * @param addFractions toggle for fractions of seconds - * @see #millisToTimeStr(long) + * @see #toTimeStr(long) */ - public static String millisToTimeStr(final long millis, final boolean addFractions) { + public static String toTimeStr(final long millis, final boolean addFractions) { final long h = TimeUnit.MILLISECONDS.toHours(millis); final long m = TimeUnit.MILLISECONDS.toMinutes(millis); if( addFractions ) { @@ -200,9 +200,9 @@ public final class PTS { /** * Returns a full time string representation 'HH:mm:ss.SSS'. * @param millis complete time in milliseconds - * @see #millisToTimeStr(long, boolean) + * @see #toTimeStr(long, boolean) */ - public static String millisToTimeStr(final long millis) { + public static String toTimeStr(final long millis) { final long h = TimeUnit.MILLISECONDS.toHours(millis); final long m = TimeUnit.MILLISECONDS.toMinutes(millis); return String.format("%02d:%02d:%02d.%03d", |