Added constructors and validity checks in the set methods of Date.