Renamed some variables and methods.