public static long ticksWithMonthSetTo ( long ticks , int month ) { int year = ticksToYears ( ticks ) ; boolean isLeapYear = isLeapYear ( year ) ; int oldMonth = ticksToMonths ( ticks ) ; return ticks - millisToStartOfMonth ( oldMonth , isLeapYear ) + millisToStartOfMonth ( month , isLeapYear ) ; }
Sets the month component of the timestamp returning the new timestamp with updated component .