1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "net/tools/quic/quic_per_connection_packet_writer.h"
11 QuicPerConnectionPacketWriter::QuicPerConnectionPacketWriter(
12 QuicPacketWriter
* shared_writer
,
13 QuicConnection
* connection
)
14 : shared_writer_(shared_writer
),
15 connection_(connection
) {
18 QuicPerConnectionPacketWriter::~QuicPerConnectionPacketWriter() {
21 WriteResult
QuicPerConnectionPacketWriter::WritePacket(
24 const IPAddressNumber
& self_address
,
25 const IPEndPoint
& peer_address
) {
26 return shared_writer_
->WritePacket(buffer
,
32 bool QuicPerConnectionPacketWriter::IsWriteBlockedDataBuffered() const {
33 return shared_writer_
->IsWriteBlockedDataBuffered();
36 bool QuicPerConnectionPacketWriter::IsWriteBlocked() const {
37 return shared_writer_
->IsWriteBlocked();
40 void QuicPerConnectionPacketWriter::SetWritable() {
41 shared_writer_
->SetWritable();