Rejects any illegal input (as attributes of this request) by the user.

@throws IllegalArgumentException if there is illegal input from the user.
772032
public void rejectIllegalArguments() {
        if (bucketName == null) {
            throw new IllegalArgumentException(
                    "The bucket name parameter must be specified when generating a pre-signed URL");
        }
        if (this.method == null) {
            throw new IllegalArgumentException(
                    "The HTTP method request parameter must be specified when generating a pre-signed URL");
        }
        if (this.sseCustomerKey != null) {
            if (this.sseAlgorithm != null) {
                throw new IllegalArgumentException("Either SSE or SSE-C can be specified but not both");
            }
            if (this.kmsCmkId != null) {
                throw new IllegalArgumentException("KMS CMK is not applicable for SSE-C");
            }
        } else if (this.kmsCmkId != null) {
            if (!SSEAlgorithm.KMS.getAlgorithm().equals(sseAlgorithm)) {
                throw new IllegalArgumentException(
                        "For KMS server side encryption, the SSE algorithm must be set to "
                                + SSEAlgorithm.KMS);
            }
        }
        /*
         * S3 does not require HTTP header
         * “x-amz-server-side-encryption-aws-kms-key-id” to be always present (a
         * default key ID will be used if this header is not present).
         *
         * It is also possible to set the header to “alias/aws/s3” to refer
         * to the default KMS CMK ID.
         */
    }
678711
public static void checkNotEmpty(CharSequence str, String message) {
    if (str == null || str.length() == 0) {
      throw new IllegalArgumentException(message);
    }
  }
24103
public void validate() {
    if (interval == null || interval.isEmpty()) {
      throw new IllegalArgumentException("Missing or empty interval");
    }
    DateTime.parseDuration(interval);
    
    if (aggregator == null || aggregator.isEmpty()) {
      throw new IllegalArgumentException("Missing or empty aggregator");
    }
    try {
      Aggregators.get(aggregator.toLowerCase());
    } catch (final NoSuchElementException e) {
      throw new IllegalArgumentException("Invalid aggregator");
    }
    
    if (fill_policy != null) {
      fill_policy.validate();
    }
  }
812962
@Override
    protected boolean validateSettings() throws IllegalArgumentException {
        // Validate values which do not require user input first to avoid unnecesary
        // work on the user part.

        // dates
        Date startDate = getStartDate();
        Date stopDate = getStopDate();
        if (startDate != null && stopDate != null) {
            if (startDate.after(stopDate)) {
                // stop date is before the start date.
                throw new IllegalArgumentException(getLocalizedString("BL_MINDATE_AFTER_MAXDATE"));
            }
        }

        // Validate levels if specified.
        Level minLevel = getMinLevel();
        Level maxLevel = getMaxLevel();
        if (maxLevel != null && minLevel != null) {
            // We have both a max and min level. Check that the min level is
            // equal to or less than the max level
            if (minLevel.intValue() > maxLevel.intValue()) {
                // Min is greater than Max level. Report error
                throw new IllegalArgumentException(getLocalizedString("BL_MINLEVEL_GREATER_THAN_MAXLEVEL"));
            }
        }

        // Required options
        try {
            setBinaryRepositoryDir(unvalidatedRepositoryDir.getCanonicalPath());
            System.out.println(getLocalizedParmString("BL_REPOSITORY_DIRECTORY", new Object[] { getValidatedBinaryRepositoryDir() }));
        } catch (IOException e) {
            throw new IllegalArgumentException(getLocalizedParmString("BL_INVALID_REPOSITORYDIR", new Object[] { unvalidatedRepositoryDir }));
        }

        // in case of copy action, we have an unvalidatedTargetDir set
        try {
            if (unvalidatedTargetDir != null) {
                String dir = unvalidatedTargetDir.getCanonicalPath();
                setOutputRepositoryDir(dir);
                System.out.println(getLocalizedParmString("BL_TARGET_DIRECTORY", new Object[] { dir }));
            }
        } catch (IOException e) {
            throw new IllegalArgumentException(getLocalizedParmString("BL_INVALID_TARGETDIR", new Object[] { unvalidatedTargetDir }));
        }

        return false;

    }
880730
protected void assertArgumentNotNull(String argumentName, Object value) {
        if (argumentName == null) {
            String msg = "The argument name should not be null: argName=null value=" + value;
            throw new IllegalArgumentException(msg);
        }
        if (value == null) {
            String msg = "The value should not be null: argName=" + argumentName;
            throw new IllegalArgumentException(msg);
        }
    }
1259889
void rejectAttributes(RejectedAttributesLogContext rejectedAttributes, ModelNode attributeValue) {
        for (RejectAttributeChecker checker : checks) {
            rejectedAttributes.checkAttribute(checker, name, attributeValue);
        }
    }
1044869
private void checkArgument(boolean argument, String msg, Object... args) {
        if (!argument) {
            throw new IllegalArgumentException(String.format(msg, args));
        }
    }
479892
private void validateFilter(Filter filter) throws IllegalArgumentException {
    switch (filter.getFilterTypeCase()) {
      case COMPOSITE_FILTER:
        for (Filter subFilter : filter.getCompositeFilter().getFiltersList()) {
          validateFilter(subFilter);
        }
        break;
      case PROPERTY_FILTER:
        if (UNSUPPORTED_OPERATORS.contains(filter.getPropertyFilter().getOp())) {
          throw new IllegalArgumentException("Query cannot have any inequality filters.");
        }
        break;
      default:
        throw new IllegalArgumentException(
            "Unsupported filter type: " + filter.getFilterTypeCase());
    }
  }
884047
protected void assertNotNullOrEmpty(String value, String message) throws IllegalArgumentException {
        if (value == null || value.length() == 0) {
            throw new IllegalArgumentException(message);
        }
    }
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");
        }
    }
621014
private static void validateCreation(String method, SipApplicationSession app) {

		if (method.equals(Request.ACK)) {
			throw new IllegalArgumentException(
					"Wrong method to create request with[" + Request.ACK + "]!");
		}
		if (method.equals(Request.PRACK)) {
			throw new IllegalArgumentException(
					"Wrong method to create request with[" + Request.PRACK + "]!");
		}
		if (method.equals(Request.CANCEL)) {
			throw new IllegalArgumentException(
					"Wrong method to create request with[" + Request.CANCEL
							+ "]!");
		}
		if (!((MobicentsSipApplicationSession)app).isValidInternal()) {
			throw new IllegalArgumentException(
					"Cant associate request with invalidaded sip session application!");
		}

	}
523612
public static void validate(String address) throws IllegalEmailAddressException {
		if (address == null) {
			throw new IllegalEmailAddressException("<null>", "Email address is null.");
		}
		if (address.length() > 254) {
			throw new IllegalEmailAddressException(address, "Email address is longer than 254 characters.");
		}
		String[] parts = address.split("@");
		if (parts.length < 2) {
			int index = address.indexOf('@');
			if (index == 0) {
				throw new IllegalEmailAddressException(address, "Local part must not be empty.");
			} else if (index == (address.length() - 1)) {
				throw new IllegalEmailAddressException(address, "Domain part must not be empty.");
			}
			throw new IllegalEmailAddressException(address, "No @ character included.");
		}
		if (parts.length > 2) {
			throw new IllegalEmailAddressException(address, "Multiple @ characters included.");
		}
		try {
			validateDomainPart(parts[1]);
			validateLocalPart(parts[0]);
		} catch (IllegalEmailAddressException e) {
			throw new IllegalEmailAddressException(address, e.getReason());
		}
	}
1352607
def execute(input, negate)
      method = negate ? :reject : :select

      input.send(method) do |object|
        content_match?([object.name])
      end
    end
332677
protected static IllegalArgumentException invalidType(
      String view, String attribute, Object value, Class<?>... expectedTypes) {
    Object expected =
        expectedTypes.length == 1 ? expectedTypes[0] : "one of " + Arrays.toString(expectedTypes);
    throw new IllegalArgumentException(
        "invalid type "
            + value.getClass()
            + " for attribute '"
            + view
            + ":"
            + attribute
            + "': expected "
            + expected);
  }
10859
private static void validateKey(String key) {
		if (key == null || key.length() > MAX_KEY_SIZE) {
			throw new IllegalArgumentException("Invalid key - must be non null and have a length less than " + MAX_KEY_SIZE);
		}
	}
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.");
        }
    }
1143985
protected function exceptionIfNotSelect()
    {
        if (!$this->isSelect()) {
            throw new RuntimeException(
                Message::get(Message::DB_RESULT_NOT_SELECT),
                Message::DB_RESULT_NOT_SELECT
            );
        }
    }