Adding support for Pattern