add interface to set timetamp before saving object