| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 #ifndef NET_TOOLS_QUIC_TEST_TOOLS_TEST_TOOLS_HTTP_MESSAGE_H_ | 5 #ifndef NET_TOOLS_QUIC_TEST_TOOLS_TEST_TOOLS_HTTP_MESSAGE_H_ |
| 6 #define NET_TOOLS_QUIC_TEST_TOOLS_TEST_TOOLS_HTTP_MESSAGE_H_ | 6 #define NET_TOOLS_QUIC_TEST_TOOLS_TEST_TOOLS_HTTP_MESSAGE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/strings/string_piece.h" | 11 #include "base/strings/string_piece.h" |
| 12 #include "net/tools/balsa/balsa_enums.h" | 12 #include "net/tools/balsa/balsa_enums.h" |
| 13 #include "net/tools/balsa/balsa_headers.h" | 13 #include "net/tools/balsa/balsa_headers.h" |
| 14 | 14 |
| 15 namespace net { | 15 namespace net { |
| 16 namespace tools { | 16 namespace tools { |
| 17 namespace test { | 17 namespace test { |
| 18 | 18 |
| 19 class HttpConstants { | 19 class HttpConstants { |
| 20 public: | 20 public: |
| 21 enum Version { | 21 enum Version { HTTP_UNKNOWN = 0, HTTP_0_9, HTTP_1_0, HTTP_1_1 }; |
| 22 HTTP_UNKNOWN = 0, | |
| 23 HTTP_0_9, | |
| 24 HTTP_1_0, | |
| 25 HTTP_1_1 | |
| 26 }; | |
| 27 | 22 |
| 28 enum Method { | 23 enum Method { |
| 29 UNKNOWN_METHOD = 0, | 24 UNKNOWN_METHOD = 0, |
| 30 OPTIONS, | 25 OPTIONS, |
| 31 GET, | 26 GET, |
| 32 HEAD, | 27 HEAD, |
| 33 POST, | 28 POST, |
| 34 PUT, | 29 PUT, |
| 35 DELETE, | 30 DELETE, |
| 36 TRACE, | 31 TRACE, |
| 37 CONNECT, | 32 CONNECT, |
| 38 | |
| 39 MKCOL, | 33 MKCOL, |
| 40 UNLOCK, | 34 UNLOCK, |
| 41 }; | 35 }; |
| 42 }; | 36 }; |
| 43 | 37 |
| 44 // Stripped down wrapper class which basically contains headers and a body. | 38 // Stripped down wrapper class which basically contains headers and a body. |
| 45 class HTTPMessage { | 39 class HTTPMessage { |
| 46 public: | 40 public: |
| 47 typedef HttpConstants::Version Version; | 41 typedef HttpConstants::Version Version; |
| 48 typedef HttpConstants::Method Method; | 42 typedef HttpConstants::Method Method; |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 void InitializeFields(); | 118 void InitializeFields(); |
| 125 | 119 |
| 126 DISALLOW_COPY_AND_ASSIGN(HTTPMessage); | 120 DISALLOW_COPY_AND_ASSIGN(HTTPMessage); |
| 127 }; | 121 }; |
| 128 | 122 |
| 129 } // namespace test | 123 } // namespace test |
| 130 } // namespace tools | 124 } // namespace tools |
| 131 } // namespace net | 125 } // namespace net |
| 132 | 126 |
| 133 #endif // NET_TOOLS_QUIC_TEST_TOOLS_TEST_TOOLS_HTTP_MESSAGE_H_ | 127 #endif // NET_TOOLS_QUIC_TEST_TOOLS_TEST_TOOLS_HTTP_MESSAGE_H_ |
| OLD | NEW |