public GuardrailRegexConfig withAction(String action) {
        setAction(action);
        return this;
    }
<p>
The guardrail action to configure when matching regular expression is detected.
</p>

@param action
       The guardrail action to configure when matching regular expression is detected.
@return Returns a reference to this object so that method calls can be chained together.
@see GuardrailSensitiveInformationAction
aws-java-sdk-bedrock/src/main/java/com/amazonaws/services/bedrock/model/GuardrailRegexConfig.java