Added methods to handle date conversion.

String to day conversion has problems caused by loss of precision.
I intend to fix that.