QUICHE team | a6ef0a6 | 2019-03-07 20:34:33 -0500 | [diff] [blame] | 1 | // Copyright (c) 2018 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/third_party/quiche/src/quic/core/qpack/qpack_test_utils.h" |
| 6 | |
| 7 | #include <limits> |
| 8 | |
| 9 | namespace quic { |
| 10 | namespace test { |
| 11 | |
| 12 | FragmentSizeGenerator FragmentModeToFragmentSizeGenerator( |
| 13 | FragmentMode fragment_mode) { |
| 14 | switch (fragment_mode) { |
| 15 | case FragmentMode::kSingleChunk: |
| 16 | return []() { return std::numeric_limits<size_t>::max(); }; |
| 17 | case FragmentMode::kOctetByOctet: |
| 18 | return []() { return 1; }; |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | } // namespace test |
| 23 | } // namespace quic |