public Filter withPattern(String pattern) {
        setPattern(pattern);
        return this;
    }
<p>
A filter pattern. For more information on the syntax of a filter pattern, see <a
href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventfiltering.html#filtering-syntax"> Filter rule
syntax</a>.
</p>

@param pattern
       A filter pattern. For more information on the syntax of a filter pattern, see <a
       href="https://docs.aws.amazon.com/lambda/latest/dg/invocation-eventfiltering.html#filtering-syntax">
       Filter rule syntax</a>.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-lambda/src/main/java/com/amazonaws/services/lambda/model/Filter.java