Renamed some methods and identifiers and added functionality