- added default pattern, optionally to be overridden by init parameter
- some constants added
- minor code cleanups