test_class.declarator: rateLimiter
test_class.original_string: LoggingRateLimiter rateLimiter;
test_class.type: LoggingRateLimiter
test_class.var_name: rateLimiter
test_class.declarator: ran= false
test_class.original_string: boolean ran= false;
test_class.type: boolean
test_class.var_name: ran
test_class.file: micro-events/src/test/java/com/oath/micro/server/events/LoggingRateLimiterTest.java
test_class.identifier: LoggingRateLimiterTest
test_case.body: @Test
  	public void testResetAfterLimit() throws InterruptedException {
  		rateLimiter = new  LoggingRateLimiter(0);
  		ConcurrentHashMultiset freq = rateLimiter.getFrequency();
  		
  		rateLimiter.resetAfterLimit();
  		
  		assertTrue (freq != rateLimiter.getFrequency() );
  		freq = rateLimiter.getFrequency();
  		Thread.sleep(1);
  		
  		rateLimiter.resetAfterLimit();
  		assertThat (freq,is( rateLimiter.getFrequency()));
  	}
test_case.class_method_signature: LoggingRateLimiterTest.testResetAfterLimit()
test_case.full_signature: @Test public void testResetAfterLimit()
test_case.identifier: testResetAfterLimit
test_case.invocations: getFrequency resetAfterLimit assertTrue getFrequency getFrequency sleep resetAfterLimit assertThat is getFrequency
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testResetAfterLimit()
focal_class.declarator: frequency = ConcurrentHashMultiset.create()
focal_class.modifier: @Getter(AccessLevel.PACKAGE)
      private volatile
focal_class.original_string: @Getter(AccessLevel.PACKAGE)
      private volatile ConcurrentHashMultiset<T> frequency = ConcurrentHashMultiset.create();
focal_class.type: ConcurrentHashMultiset<T>
focal_class.var_name: frequency
focal_class.declarator: lastCleared = new Date(
                                                   0)
focal_class.modifier: private volatile
focal_class.original_string: private volatile Date lastCleared = new Date(
                                                   0);
focal_class.type: Date
focal_class.var_name: lastCleared
focal_class.declarator: limit
focal_class.modifier: private final
focal_class.original_string: private final int limit;
focal_class.type: int
focal_class.var_name: limit
focal_class.file: micro-events/src/main/java/com/oath/micro/server/events/LoggingRateLimiter.java
focal_class.identifier: LoggingRateLimiter
focal_class.class_method_signature: LoggingRateLimiter.LoggingRateLimiter(int limit)
focal_class.full_signature: public  LoggingRateLimiter(int limit)
focal_class.identifier: LoggingRateLimiter
focal_class.modifiers: public
focal_class.parameters: (int limit)
focal_class.signature:  LoggingRateLimiter(int limit)
focal_class.class_method_signature: LoggingRateLimiter.LoggingRateLimiter()
focal_class.full_signature: public  LoggingRateLimiter()
focal_class.identifier: LoggingRateLimiter
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  LoggingRateLimiter()
focal_class.class_method_signature: LoggingRateLimiter.addAndEnsureFrequency(T clazz)
focal_class.full_signature: public void addAndEnsureFrequency(T clazz)
focal_class.identifier: addAndEnsureFrequency
focal_class.modifiers: public
focal_class.parameters: (T clazz)
focal_class.return: void
focal_class.signature: void addAndEnsureFrequency(T clazz)
focal_class.class_method_signature: LoggingRateLimiter.resetAfterLimit()
focal_class.full_signature: public void resetAfterLimit()
focal_class.identifier: resetAfterLimit
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void resetAfterLimit()
focal_class.class_method_signature: LoggingRateLimiter.capacityAvailable(T t, long max, Runnable run)
focal_class.full_signature: public void capacityAvailable(T t, long max, Runnable run)
focal_class.identifier: capacityAvailable
focal_class.modifiers: public
focal_class.parameters: (T t, long max, Runnable run)
focal_class.return: void
focal_class.signature: void capacityAvailable(T t, long max, Runnable run)
focal_method.body: public void resetAfterLimit() {
          if (System.currentTimeMillis() - limit > lastCleared.getTime()) {
              frequency = ConcurrentHashMultiset.create();
              lastCleared = new Date(
                                     System.currentTimeMillis());
          }
  
      }
focal_method.class_method_signature: LoggingRateLimiter.resetAfterLimit()
focal_method.full_signature: public void resetAfterLimit()
focal_method.identifier: resetAfterLimit
focal_method.invocations: currentTimeMillis getTime create currentTimeMillis
focal_method.modifiers: public
focal_method.parameters: ()
focal_method.return: void
focal_method.signature: void resetAfterLimit()