changed pattern to singleton
implemented file and line information