add common methods to Time class