code: public static void checkNotNullOrEmpty(String string, String message) {
      if (string == null || string.isEmpty()) {
        throw new IllegalArgumentException(message);
      }
    }
docs: Validation method, which checks if a string is null or empty
  
  @param string to verify
  @param message to be thrown in exception