Class MathUtils

java.lang.Object
com.couchbase.client.dcp.util.MathUtils

public class MathUtils extends Object
Various math utility methods, also backports from later JDK versions.
Since:
0.10.0
Author:
Sergey Avseyev
  • Constructor Details

    • MathUtils

      public MathUtils()
  • Method Details

    • lessThanUnsigned

      public static boolean lessThanUnsigned(long x, long y)
      Compares two numbers as unsigned 64-bit integers.
      Parameters:
      x - left operand
      y - right operand
      Returns:
      true if x is less than y
    • compareLong

      @Deprecated public static int compareLong(long x, long y)
      Deprecated.
      Backport of Long.compare from Java 7.
    • compareUnsignedLong

      @Deprecated public static int compareUnsignedLong(long x, long y)
      Deprecated.
      Backport of Long.compareUnsigned from Java 8.