Allow QuicSession::WritevData() to write data at a specified encryption level.
gfe-relnote: protected by gfe2_reloadable_flag_quic_writevdata_at_level
PiperOrigin-RevId: 297697074
Change-Id: Ib4e5d860f22f506f36db76f4f8ee1c1e406f6a20
diff --git a/quic/core/quic_crypto_stream.h b/quic/core/quic_crypto_stream.h
index ecd3201..d07a4e7 100644
--- a/quic/core/quic_crypto_stream.h
+++ b/quic/core/quic_crypto_stream.h
@@ -14,6 +14,7 @@
#include "net/third_party/quiche/src/quic/core/quic_config.h"
#include "net/third_party/quiche/src/quic/core/quic_packets.h"
#include "net/third_party/quiche/src/quic/core/quic_stream.h"
+#include "net/third_party/quiche/src/quic/core/quic_types.h"
#include "net/third_party/quiche/src/quic/platform/api/quic_export.h"
#include "net/third_party/quiche/src/common/platform/api/quiche_string_piece.h"
@@ -120,6 +121,12 @@
QuicByteCount data_length,
bool fin) override;
+ // Sends stream retransmission data at |encryption_level|.
+ QuicConsumedData RetransmitStreamDataAtLevel(
+ QuicStreamOffset retransmission_offset,
+ QuicByteCount retransmission_length,
+ EncryptionLevel encryption_level);
+
// Returns the number of bytes of handshake data that have been received from
// the peer in either CRYPTO or STREAM frames.
uint64_t crypto_bytes_read() const;
@@ -186,6 +193,9 @@
// Keeps state for data sent/received in CRYPTO frames at each encryption
// level.
std::array<CryptoSubstream, NUM_ENCRYPTION_LEVELS> substreams_;
+
+ // Latched value of gfe2_reloadable_flag_quic_writevdata_at_level.
+ const bool writevdata_at_level_;
};
} // namespace quic