Exemplo n.º 1
0
  /**
   * Called from the {@link Receiver} upon receiving an RTT Measurement that is a reply.
   *
   * @param header of the measurement
   * @param srcAddress from the sender of the measurement
   */
  public void onRttMeasurement(
      final RttMeasurementFlyweight header, final InetSocketAddress srcAddress) {
    final long now = nanoClock.nanoTime();
    final long rttInNanos = now - header.echoTimestamp() - header.receptionDelta();

    congestionControl.onRttMeasurement(now, rttInNanos, srcAddress);
  }