コード例 #1
0
 /** Ensures the truth of an expression, with an error message. */
 public static void checkArgument(boolean expression, String errorMessage) {
   checkArgumentInternal(expression, true, errorMessage, EMPTY_ARGUMENTS);
 }
コード例 #2
0
 /** Ensures the truth of an expression, with an error message that takes arguments. */
 public static void checkArgument(
     boolean expression, String errorMessageTemplate, Object... errorMessageArgs) {
   checkArgumentInternal(expression, true, errorMessageTemplate, errorMessageArgs);
 }
コード例 #3
0
 /** Ensures the truth of an expression. */
 public static void checkArgument(boolean expression) {
   checkArgumentInternal(expression, true, "Illegal argument.", EMPTY_ARGUMENTS);
 }