Added const to some method parameters.