test_class.declarator: timeout = 300L
test_class.modifier: private
test_class.original_string: private long timeout = 300L;
test_class.type: long
test_class.var_name: timeout
test_class.declarator: interval = 100L
test_class.modifier: private
test_class.original_string: private long interval = 100L;
test_class.type: long
test_class.var_name: interval
test_class.declarator: time = new MockTime()
test_class.modifier: private
test_class.original_string: private MockTime time = new MockTime();
test_class.type: MockTime
test_class.var_name: time
test_class.declarator: heartbeat = new Heartbeat(timeout, interval, -1L)
test_class.modifier: private
test_class.original_string: private Heartbeat heartbeat = new Heartbeat(timeout, interval, -1L);
test_class.type: Heartbeat
test_class.var_name: heartbeat
test_class.file: clients/src/test/java/org/apache/kafka/clients/consumer/internals/HeartbeatTest.java
test_class.identifier: HeartbeatTest
test_case.body: @Test
      public void testSessionTimeoutExpired() {
          heartbeat.sentHeartbeat(time.milliseconds());
          time.sleep(305);
          assertTrue(heartbeat.sessionTimeoutExpired(time.milliseconds()));
      }
test_case.class_method_signature: HeartbeatTest.testSessionTimeoutExpired()
test_case.full_signature: @Test public void testSessionTimeoutExpired()
test_case.identifier: testSessionTimeoutExpired
test_case.invocations: sentHeartbeat milliseconds sleep assertTrue sessionTimeoutExpired milliseconds
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testSessionTimeoutExpired()
focal_class.declarator: timeout
focal_class.modifier: private final
focal_class.original_string: private final long timeout;
focal_class.type: long
focal_class.var_name: timeout
focal_class.declarator: interval
focal_class.modifier: private final
focal_class.original_string: private final long interval;
focal_class.type: long
focal_class.var_name: interval
focal_class.declarator: lastHeartbeatSend
focal_class.modifier: private
focal_class.original_string: private long lastHeartbeatSend;
focal_class.type: long
focal_class.var_name: lastHeartbeatSend
focal_class.declarator: lastHeartbeatReceive
focal_class.modifier: private
focal_class.original_string: private long lastHeartbeatReceive;
focal_class.type: long
focal_class.var_name: lastHeartbeatReceive
focal_class.declarator: lastSessionReset
focal_class.modifier: private
focal_class.original_string: private long lastSessionReset;
focal_class.type: long
focal_class.var_name: lastSessionReset
focal_class.file: clients/src/main/java/org/apache/kafka/clients/consumer/internals/Heartbeat.java
focal_class.identifier: Heartbeat
focal_class.class_method_signature: Heartbeat.Heartbeat(long timeout,
                       long interval,
                       long now)
focal_class.full_signature: public  Heartbeat(long timeout,
                       long interval,
                       long now)
focal_class.identifier: Heartbeat
focal_class.modifiers: public
focal_class.parameters: (long timeout,
                       long interval,
                       long now)
focal_class.signature:  Heartbeat(long timeout,
                       long interval,
                       long now)
focal_class.class_method_signature: Heartbeat.sentHeartbeat(long now)
focal_class.full_signature: public void sentHeartbeat(long now)
focal_class.identifier: sentHeartbeat
focal_class.modifiers: public
focal_class.parameters: (long now)
focal_class.return: void
focal_class.signature: void sentHeartbeat(long now)
focal_class.class_method_signature: Heartbeat.receiveHeartbeat(long now)
focal_class.full_signature: public void receiveHeartbeat(long now)
focal_class.identifier: receiveHeartbeat
focal_class.modifiers: public
focal_class.parameters: (long now)
focal_class.return: void
focal_class.signature: void receiveHeartbeat(long now)
focal_class.class_method_signature: Heartbeat.shouldHeartbeat(long now)
focal_class.full_signature: public boolean shouldHeartbeat(long now)
focal_class.identifier: shouldHeartbeat
focal_class.modifiers: public
focal_class.parameters: (long now)
focal_class.return: boolean
focal_class.signature: boolean shouldHeartbeat(long now)
focal_class.class_method_signature: Heartbeat.lastHeartbeatSend()
focal_class.full_signature: public long lastHeartbeatSend()
focal_class.identifier: lastHeartbeatSend
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long lastHeartbeatSend()
focal_class.class_method_signature: Heartbeat.timeToNextHeartbeat(long now)
focal_class.full_signature: public long timeToNextHeartbeat(long now)
focal_class.identifier: timeToNextHeartbeat
focal_class.modifiers: public
focal_class.parameters: (long now)
focal_class.return: long
focal_class.signature: long timeToNextHeartbeat(long now)
focal_class.class_method_signature: Heartbeat.sessionTimeoutExpired(long now)
focal_class.full_signature: public boolean sessionTimeoutExpired(long now)
focal_class.identifier: sessionTimeoutExpired
focal_class.modifiers: public
focal_class.parameters: (long now)
focal_class.return: boolean
focal_class.signature: boolean sessionTimeoutExpired(long now)
focal_class.class_method_signature: Heartbeat.interval()
focal_class.full_signature: public long interval()
focal_class.identifier: interval
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long interval()
focal_class.class_method_signature: Heartbeat.resetSessionTimeout(long now)
focal_class.full_signature: public void resetSessionTimeout(long now)
focal_class.identifier: resetSessionTimeout
focal_class.modifiers: public
focal_class.parameters: (long now)
focal_class.return: void
focal_class.signature: void resetSessionTimeout(long now)
focal_method.body: public boolean sessionTimeoutExpired(long now) {
          return now - Math.max(lastSessionReset, lastHeartbeatReceive) > timeout;
      }
focal_method.class_method_signature: Heartbeat.sessionTimeoutExpired(long now)
focal_method.full_signature: public boolean sessionTimeoutExpired(long now)
focal_method.identifier: sessionTimeoutExpired
focal_method.invocations: max
focal_method.modifiers: public
focal_method.parameters: (long now)
focal_method.return: boolean
focal_method.signature: boolean sessionTimeoutExpired(long now)