Class Utils


  • @Immutable
    public final class Utils
    extends Object
    General internal utility methods.
    • Method Detail

      • checkArgument

        public static void checkArgument​(boolean isValid,
                                         String errorMessage)
        Throws an IllegalArgumentException if the argument is false. This method is similar to Preconditions.checkArgument(boolean, Object) from Guava.
        Parameters:
        isValid - whether the argument check passed.
        errorMessage - the message to use for the exception.