presto-matching/src/main/java/io/prestosql/matching/Pattern.java/Pattern/capturedAs
class Pattern:    public Pattern<T> capturedAs(Capture<T> capture)
    {
        return new CapturePattern<>(capture, this);
    }