Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(365)

Side by Side Diff: net/quic/core/quic_versions.cc

Issue 2740453006: Add QuicStringPiece which is actually StringPiece. (Closed)
Patch Set: fix compile error and rebase Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « net/quic/core/quic_utils_test.cc ('k') | net/quic/core/spdy_utils.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/quic/core/quic_versions.h" 5 #include "net/quic/core/quic_versions.h"
6 6
7 #include "base/strings/string_piece.h"
8 #include "net/quic/core/quic_error_codes.h" 7 #include "net/quic/core/quic_error_codes.h"
9 #include "net/quic/core/quic_flags.h" 8 #include "net/quic/core/quic_flags.h"
10 #include "net/quic/core/quic_tag.h" 9 #include "net/quic/core/quic_tag.h"
11 #include "net/quic/core/quic_types.h" 10 #include "net/quic/core/quic_types.h"
12 #include "net/quic/platform/api/quic_logging.h" 11 #include "net/quic/platform/api/quic_logging.h"
13 12
14 using base::StringPiece;
15 using std::string; 13 using std::string;
16 14
17 namespace net { 15 namespace net {
18 16
19 QuicVersionVector AllSupportedVersions() { 17 QuicVersionVector AllSupportedVersions() {
20 QuicVersionVector supported_versions; 18 QuicVersionVector supported_versions;
21 for (size_t i = 0; i < arraysize(kSupportedQuicVersions); ++i) { 19 for (size_t i = 0; i < arraysize(kSupportedQuicVersions); ++i) {
22 supported_versions.push_back(kSupportedQuicVersions[i]); 20 supported_versions.push_back(kSupportedQuicVersions[i]);
23 } 21 }
24 return supported_versions; 22 return supported_versions;
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 for (size_t i = 0; i < versions.size(); ++i) { 120 for (size_t i = 0; i < versions.size(); ++i) {
123 if (i != 0) { 121 if (i != 0) {
124 result.append(","); 122 result.append(",");
125 } 123 }
126 result.append(QuicVersionToString(versions[i])); 124 result.append(QuicVersionToString(versions[i]));
127 } 125 }
128 return result; 126 return result;
129 } 127 }
130 128
131 } // namespace net 129 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/core/quic_utils_test.cc ('k') | net/quic/core/spdy_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698