Replaced the use of deprecated classes with new ones so that the plugin works on SonarQube 4.2+