Class Timespan

java.lang.Object
ch.njol.skript.util.Timespan
All Implemented Interfaces:
YggdrasilSerializable, Comparable<Timespan>

public class Timespan extends Object implements YggdrasilSerializable, Comparable<Timespan>
  • Constructor Details

    • Timespan

      public Timespan()
    • Timespan

      public Timespan(long millis)
  • Method Details

    • parse

      public static @Nullable Timespan parse(String s)
    • fromTicks

      @Deprecated public static Timespan fromTicks(int ticks)
      Deprecated.
      Use fromTicks_i(long ticks) instead. Since this method limits timespan to 50 * Integer.MAX_VALUE.
    • fromTicks_i

      public static Timespan fromTicks_i(long ticks)
    • getMilliSeconds

      public long getMilliSeconds()
    • getTicks_i

      public long getTicks_i()
    • getTicks

      @Deprecated public int getTicks()
      Deprecated.
      Use getTicks_i() instead. Since this method limits timespan to Integer.MAX_VALUE.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toString

      public String toString(int flags)
    • toString

      public static String toString(long millis)
    • toString

      public static String toString(long millis, int flags)
    • compareTo

      public int compareTo(@Nullable Timespan o)
      Specified by:
      compareTo in interface Comparable<Timespan>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(@Nullable Object obj)
      Overrides:
      equals in class Object