public long getResetMillis ( RateBucketPeriod period ) { long now = System . currentTimeMillis ( ) ; long periodBoundary = getPeriodBoundary ( now , period ) ; return periodBoundary - now ; }
Returns the number of millis until the period resets .