public Pattern getPattern() {
        return pattern;
    }
Gets the regex pattern.

@return returns compiled regular expression.
smithy-model/src/main/java/software/amazon/smithy/model/traits/PatternTrait.java