1 // Copyright (c) 2013 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. 4 5 #include "net/quic/test_tools/quic_framer_peer.h" 6 7 #include "net/quic/quic_framer.h" 8 #include "net/quic/quic_protocol.h" 9 10 namespace net { 11 namespace test { 12 13 // static 14 QuicPacketSequenceNumber QuicFramerPeer::CalculatePacketSequenceNumberFromWire( 15 QuicFramer* framer, 16 QuicSequenceNumberLength sequence_number_length, 17 QuicPacketSequenceNumber packet_sequence_number) { 18 return framer->CalculatePacketSequenceNumberFromWire(sequence_number_length, 19 packet_sequence_number); 20 } 21 22 // static 23 void QuicFramerPeer::SetLastSerializedGuid(QuicFramer* framer, QuicGuid guid) { 24 framer->last_serialized_guid_ = guid; 25 } 26 27 void QuicFramerPeer::SetLastSequenceNumber( 28 QuicFramer* framer, 29 QuicPacketSequenceNumber packet_sequence_number) { 30 framer->last_sequence_number_ = packet_sequence_number; 31 } 32 33 void QuicFramerPeer::SetIsServer(QuicFramer* framer, bool is_server) { 34 framer->is_server_ = is_server; 35 } 36 37 } // namespace test 38 } // namespace net 39