public static long ticksWithYearSetTo ( long ticks , int year ) { int oldYear = ticksToYears ( ticks ) ; return ticks - millisToYearStart ( oldYear ) + millisToYearStart ( year ) ; }
Sets the year component of the timestamp returning the new timestamp with updated component .