add property to read or write date components.
small refactoring.