add printMultiLine method in Pattern class