Refactor DateAndTime class.