| Index: net/quic/core/quic_packets.h
|
| diff --git a/net/quic/core/quic_packets.h b/net/quic/core/quic_packets.h
|
| index 788cf42dbc43c9b249c77202d6f6a792a80a732d..d85123b6fcee3ffc27b28be720790a67cbbf5104 100644
|
| --- a/net/quic/core/quic_packets.h
|
| +++ b/net/quic/core/quic_packets.h
|
| @@ -20,6 +20,7 @@
|
| #include "net/base/int128.h"
|
| #include "net/base/iovec.h"
|
| #include "net/base/net_export.h"
|
| +#include "net/quic/core/quic_ack_listener_interface.h"
|
| #include "net/quic/core/quic_bandwidth.h"
|
| #include "net/quic/core/quic_constants.h"
|
| #include "net/quic/core/quic_error_codes.h"
|
| @@ -218,38 +219,6 @@ class NET_EXPORT_PRIVATE QuicReceivedPacket : public QuicEncryptedPacket {
|
| DISALLOW_COPY_AND_ASSIGN(QuicReceivedPacket);
|
| };
|
|
|
| -// Pure virtual class to listen for packet acknowledgements.
|
| -class NET_EXPORT_PRIVATE QuicAckListenerInterface
|
| - : public base::RefCounted<QuicAckListenerInterface> {
|
| - public:
|
| - QuicAckListenerInterface() {}
|
| -
|
| - // Called when a packet is acked. Called once per packet.
|
| - // |acked_bytes| is the number of data bytes acked.
|
| - virtual void OnPacketAcked(int acked_bytes,
|
| - QuicTime::Delta ack_delay_time) = 0;
|
| -
|
| - // Called when a packet is retransmitted. Called once per packet.
|
| - // |retransmitted_bytes| is the number of data bytes retransmitted.
|
| - virtual void OnPacketRetransmitted(int retransmitted_bytes) = 0;
|
| -
|
| - protected:
|
| - friend class base::RefCounted<QuicAckListenerInterface>;
|
| -
|
| - // Delegates are ref counted.
|
| - virtual ~QuicAckListenerInterface() {}
|
| -};
|
| -
|
| -struct NET_EXPORT_PRIVATE AckListenerWrapper {
|
| - AckListenerWrapper(QuicAckListenerInterface* listener,
|
| - QuicPacketLength data_length);
|
| - AckListenerWrapper(const AckListenerWrapper& other);
|
| - ~AckListenerWrapper();
|
| -
|
| - scoped_refptr<QuicAckListenerInterface> ack_listener;
|
| - QuicPacketLength length;
|
| -};
|
| -
|
| struct NET_EXPORT_PRIVATE SerializedPacket {
|
| SerializedPacket(QuicPathId path_id,
|
| QuicPacketNumber packet_number,
|
| @@ -292,77 +261,6 @@ NET_EXPORT_PRIVATE void ClearSerializedPacket(
|
| // |packet.encrypted_buffer|.
|
| NET_EXPORT_PRIVATE char* CopyBuffer(const SerializedPacket& packet);
|
|
|
| -struct NET_EXPORT_PRIVATE TransmissionInfo {
|
| - // Used by STL when assigning into a map.
|
| - TransmissionInfo();
|
| -
|
| - // Constructs a Transmission with a new all_transmissions set
|
| - // containing |packet_number|.
|
| - TransmissionInfo(EncryptionLevel level,
|
| - QuicPacketNumberLength packet_number_length,
|
| - TransmissionType transmission_type,
|
| - QuicTime sent_time,
|
| - QuicPacketLength bytes_sent,
|
| - bool has_crypto_handshake,
|
| - int num_padding_bytes);
|
| -
|
| - TransmissionInfo(const TransmissionInfo& other);
|
| -
|
| - ~TransmissionInfo();
|
| -
|
| - QuicFrames retransmittable_frames;
|
| - EncryptionLevel encryption_level;
|
| - QuicPacketNumberLength packet_number_length;
|
| - QuicPacketLength bytes_sent;
|
| - QuicTime sent_time;
|
| - // Reason why this packet was transmitted.
|
| - TransmissionType transmission_type;
|
| - // In flight packets have not been abandoned or lost.
|
| - bool in_flight;
|
| - // True if the packet can never be acked, so it can be removed. Occurs when
|
| - // a packet is never sent, after it is acknowledged once, or if it's a crypto
|
| - // packet we never expect to receive an ack for.
|
| - bool is_unackable;
|
| - // True if the packet contains stream data from the crypto stream.
|
| - bool has_crypto_handshake;
|
| - // Non-zero if the packet needs padding if it's retransmitted.
|
| - int16_t num_padding_bytes;
|
| - // Stores the packet number of the next retransmission of this packet.
|
| - // Zero if the packet has not been retransmitted.
|
| - QuicPacketNumber retransmission;
|
| - // Non-empty if there is a std::listener for this packet.
|
| - std::list<AckListenerWrapper> ack_listeners;
|
| -};
|
| -
|
| -// Struct to store the pending retransmission information.
|
| -struct PendingRetransmission {
|
| - PendingRetransmission(QuicPathId path_id,
|
| - QuicPacketNumber packet_number,
|
| - TransmissionType transmission_type,
|
| - const QuicFrames& retransmittable_frames,
|
| - bool has_crypto_handshake,
|
| - int num_padding_bytes,
|
| - EncryptionLevel encryption_level,
|
| - QuicPacketNumberLength packet_number_length)
|
| - : packet_number(packet_number),
|
| - retransmittable_frames(retransmittable_frames),
|
| - transmission_type(transmission_type),
|
| - path_id(path_id),
|
| - has_crypto_handshake(has_crypto_handshake),
|
| - num_padding_bytes(num_padding_bytes),
|
| - encryption_level(encryption_level),
|
| - packet_number_length(packet_number_length) {}
|
| -
|
| - QuicPacketNumber packet_number;
|
| - const QuicFrames& retransmittable_frames;
|
| - TransmissionType transmission_type;
|
| - QuicPathId path_id;
|
| - bool has_crypto_handshake;
|
| - int num_padding_bytes;
|
| - EncryptionLevel encryption_level;
|
| - QuicPacketNumberLength packet_number_length;
|
| -};
|
| -
|
| } // namespace net
|
|
|
| #endif // NET_QUIC_QUIC_PROTOCOL_H_
|
|
|