Package generic.util

Class UnsignedDataUtils

java.lang.Object
generic.util.UnsignedDataUtils

public class UnsignedDataUtils extends Object
A class for performing unsigned comparisons of java primitives.
  • Method Details

    • main

      public static void main(String[] args)
      Simple test for the Comp class.
      Parameters:
      args - not used
    • unsignedLessThan

      public static boolean unsignedLessThan(byte i, byte j)
      Returns true if i is LESS THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than j
    • unsignedLessThanOrEqual

      public static boolean unsignedLessThanOrEqual(byte i, byte j)
      Returns true if i is LESS THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than or equal to j
    • unsignedGreaterThan

      public static boolean unsignedGreaterThan(byte i, byte j)
      Returns true if i is GREATER THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is greater than j
    • unsignedGreaterThanOrEqual

      public static boolean unsignedGreaterThanOrEqual(byte i, byte j)
      Returns true if i is GREATER THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is greater than or equal to j
    • unsignedLessThan

      public static boolean unsignedLessThan(short i, short j)
      Returns true if i is LESS THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than j
    • unsignedLessThanOrEqual

      public static boolean unsignedLessThanOrEqual(short i, short j)
      Returns true if i is LESS THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than or equal to j
    • unsignedGreaterThan

      public static boolean unsignedGreaterThan(short i, short j)
      Returns true if i is GREATER THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is greater than j
    • unsignedGreaterThanOrEqual

      public static boolean unsignedGreaterThanOrEqual(short i, short j)
      Returns true if i is GREATER THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is greater than or equal to j
    • unsignedLessThan

      public static boolean unsignedLessThan(int i, int j)
      Returns true if i is LESS THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than j
    • unsignedLessThanOrEqual

      public static boolean unsignedLessThanOrEqual(int i, int j)
      Returns true if i is LESS THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than or equal to j
    • unsignedGreaterThan

      public static boolean unsignedGreaterThan(int i, int j)
      Returns true if i is GREATER THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is greater than j
    • unsignedGreaterThanOrEqual

      public static boolean unsignedGreaterThanOrEqual(int i, int j)
      Returns true if i is GREATER THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is greater than or equal to j
    • unsignedLessThan

      public static boolean unsignedLessThan(long i, long j)
      Returns true if i is LESS THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than j
    • unsignedLessThanOrEqual

      public static boolean unsignedLessThanOrEqual(long i, long j)
      Returns true if i is LESS THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      true if i is less than or equal to j
    • unsignedGreaterThan

      public static boolean unsignedGreaterThan(long i, long j)
      Returns true if i is GREATER THAN j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      return true if i is greater than j
    • unsignedGreaterThanOrEqual

      public static boolean unsignedGreaterThanOrEqual(long i, long j)
      Returns true if i is GREATER THAN or EQUAL TO j.
      Parameters:
      i - an argument
      j - another argument
      Returns:
      return true if i is greater than or equal to j