modified hash method, add DbLayer class.