Made accessor methods const - captured variables in lambdas are const by default.