/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.wafv2.model; import javax.annotation.Generated; /** *

* The operation failed because WAF didn't recognize a parameter in the request. For example: *

* */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class WAFInvalidParameterException extends com.amazonaws.services.wafv2.model.AWSWAFV2Exception { private static final long serialVersionUID = 1L; /** *

* The settings where the invalid parameter was found. *

*/ private String field; /** *

* The invalid parameter that resulted in the exception. *

*/ private String parameter; /** *

* Additional information about the exception. *

*/ private String reason; /** * Constructs a new WAFInvalidParameterException with the specified error message. * * @param message * Describes the error encountered. */ public WAFInvalidParameterException(String message) { super(message); } /** *

* The settings where the invalid parameter was found. *

* * @param field * The settings where the invalid parameter was found. * @see ParameterExceptionField */ @com.fasterxml.jackson.annotation.JsonProperty("Field") public void setField(String field) { this.field = field; } /** *

* The settings where the invalid parameter was found. *

* * @return The settings where the invalid parameter was found. * @see ParameterExceptionField */ @com.fasterxml.jackson.annotation.JsonProperty("Field") public String getField() { return this.field; } /** *

* The settings where the invalid parameter was found. *

* * @param field * The settings where the invalid parameter was found. * @return Returns a reference to this object so that method calls can be chained together. * @see ParameterExceptionField */ public WAFInvalidParameterException withField(String field) { setField(field); return this; } /** *

* The settings where the invalid parameter was found. *

* * @param field * The settings where the invalid parameter was found. * @return Returns a reference to this object so that method calls can be chained together. * @see ParameterExceptionField */ public WAFInvalidParameterException withField(ParameterExceptionField field) { this.field = field.toString(); return this; } /** *

* The invalid parameter that resulted in the exception. *

* * @param parameter * The invalid parameter that resulted in the exception. */ @com.fasterxml.jackson.annotation.JsonProperty("Parameter") public void setParameter(String parameter) { this.parameter = parameter; } /** *

* The invalid parameter that resulted in the exception. *

* * @return The invalid parameter that resulted in the exception. */ @com.fasterxml.jackson.annotation.JsonProperty("Parameter") public String getParameter() { return this.parameter; } /** *

* The invalid parameter that resulted in the exception. *

* * @param parameter * The invalid parameter that resulted in the exception. * @return Returns a reference to this object so that method calls can be chained together. */ public WAFInvalidParameterException withParameter(String parameter) { setParameter(parameter); return this; } /** *

* Additional information about the exception. *

* * @param reason * Additional information about the exception. */ @com.fasterxml.jackson.annotation.JsonProperty("Reason") public void setReason(String reason) { this.reason = reason; } /** *

* Additional information about the exception. *

* * @return Additional information about the exception. */ @com.fasterxml.jackson.annotation.JsonProperty("Reason") public String getReason() { return this.reason; } /** *

* Additional information about the exception. *

* * @param reason * Additional information about the exception. * @return Returns a reference to this object so that method calls can be chained together. */ public WAFInvalidParameterException withReason(String reason) { setReason(reason); return this; } }