Add Pattern class and event data retrieval methods

Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Add showpattern example

Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>