Checks that the input value is non-zero
@param input the input to check
@param inputName the name of the input
@throws IllegalArgumentException if input is null or if the input is zero
185099
public static void notZero(final Integer input, final String inputName) {
        notNull(input, inputName);

        if (input == 0) {
            throw new IllegalArgumentException("a zero value for was unexpected for " + maskNullArgument(inputName) + ", it is expected to be non zero");
        }
    }
1327832
public void setInput(final String input)
		throws DecodingException
	{

		boolean zipFlag = input.charAt(0) == '_';
		if (zipFlag) {
			r = new BitReader(inflateInput(
					Base64.decodeBase64(input.substring(1)), 0));
		}
		else {
			byte[] data = Base64.decodeBase64(input);
			if (data == null) {

				for (int i = 0; i < input.length(); i++) {
					System.err.println(i + ": " + (int) input.charAt(i)
							+ " <> " + input.charAt(i));
				}

				throw new DecodingException("BASE 64 DECODING FAILED: " + input);
			}
			r = new BitReader(data);
		}
	}
867607
private static void check(Vector a, Vector b) {
        if (a.length() != b.length())
            throw new IllegalArgumentException(
                    "input vector lengths do not match");
    }
912884
public static void instanceOf(final Object input, Class<?> classType, final String inputName) {
        notNull(input, "input");
        notNull(classType, "classType");

        if (!classType.isInstance(input)) {
            throw new IllegalArgumentException("Expecting " + maskNullArgument(inputName) + " to an instance of " + classType.getName() + ".");
        }
    }
901024
@Override
    public boolean isValid(Object input) {
        long epochMillisec;
        try {
            epochMillisec = Long.parseLong(input.toString());
        } catch (NumberFormatException e) {
            return false;
        }

        if (minValidTime != null && epochMillisec < minValidTime)
            return false;
        return !(maxValidTime != null && epochMillisec > maxValidTime);
    }
585514
public static void isPositive(Integer value, String name) {
    notNull(value, name);

    if (value < 0) {
      throw new IllegalArgumentException(name + "must be a positive number.");
    }
  }
990631
public static void notNull(final Object arg, final String name) {
        if(arg == null) {
            throw new IllegalArgumentException(String.format("%s should not be null.", name));
        }
    }
946785
public static <T> T assertNotNull(T value, String name) {
        if (value == null)
            throw new IllegalArgumentException("Null " + name);

        return value;
    }
66053
public static void isNotEmpty( Collection<?> argument,
                                   String name ) {
        isNotNull(argument, name);
        if (argument.isEmpty()) {
            throw new IllegalArgumentException(CommonI18n.argumentMayNotBeEmpty.text(name));
        }
    }
1146034
public void setInput(final byte[] input)
	{

		if (input[0] == -128) {
			r = new BitReader(inflateInput(input, 1));
		}
		else {
			r = new BitReader(input);
		}
	}
108602
static void checkInternalName(final String name, final String msg) {
        if (name == null || name.length() == 0) {
            throw new IllegalArgumentException("Invalid " + msg
                    + " (must not be null or empty)");
        }
        if (name.charAt(0) == '[') {
            checkDesc(name, false);
        } else {
            checkInternalName(name, 0, -1, msg);
        }
    }
710796
public void setInput(String key, String value) {
        if (getAllowedKeys() != null && !getAllowedKeys().contains(key))
            throw new IllegalStateException("The input key " + key + " is not allowed for lookups");

        _inputs.put(key, value);
    }
1189972
private void validateInput(AuthenticationService authenticationService, String username) throws AuthenticationException {
        if (authenticationService == null) {
            throw new AuthenticationException("authenticationService cannot be null.");
        } else if (username == null) {
            throw new AuthenticationException("username cannot be null.");
        }
    }
539268
public static void empty(String parameter, String name) {
		if (parameter == null || !parameter.isEmpty()) {
			throw new IllegalArgumentException(name + " is null or not empty.");
		}
	}
931808
public static boolean isStringNullOrEmpty(final String input) {
        if (input == null || input.trim().isEmpty()) {
            return true;
        }
        return false;

    }
1260349
public static void isNonPositive( int argument,
                                      String name ) {
        if (argument > 0) {
            throw new IllegalArgumentException(CommonI18n.argumentMayNotBePositive.text(name, argument));
        }
    }
483526
@Override
    public boolean isValid(Object input) {
        boolean value;
        try {
            value = Boolean.parseBoolean(input.toString());
        } catch (NumberFormatException e) {
            return false;
        }


        return true;
    }