In quicconnection, refactor the code to calculate release time delay into a separate function. no behavior change.

PiperOrigin-RevId: 310392260
Change-Id: Ic3b63af5fa3f3bb89c75c312c1296860fa475a3a
diff --git a/quic/core/quic_connection.h b/quic/core/quic_connection.h
index a9e1d7b..1bfacee 100644
--- a/quic/core/quic_connection.h
+++ b/quic/core/quic_connection.h
@@ -1259,6 +1259,13 @@
   // Whether connection is limited by amplification factor.
   bool LimitedByAmplificationFactor() const;
 
+  // Called before sending a packet to get packet send time and to set the
+  // release time delay in |per_packet_options_|. Return the time when the
+  // packet is scheduled to be released(a.k.a send time), which is NOW + delay.
+  // Returns Now() and does not update release time delay if
+  // |supports_release_time_| is false.
+  QuicTime CalculatePacketSentTime();
+
   // We've got a packet write error, should we ignore it?
   // NOTE: This is not a const function - if return true, the max packet size is
   // reverted to a previous(smaller) value to avoid write errors in the future.