Added 'const' or '&' to arguments when needed.

I was learning DAO's code. I found that it would be more simpler to understand code if there are const qualifiers for function arguments. Also, in this way we can avoid some errors and help compiler.

About references -- whenever we don't need object's copy -- we just use it's reference.