Convert date (without time) types to/from a Date object.