updated copyright, improved coding style, and added missing virtual keywords