Add StackTrace class and corresponding convenience function printstacktrace().

The stacktrace output is a html table with phpstorm integration via the remote call plugin.