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

Unified Diff: net/tools/balsa/balsa_headers_token_utils.h

Issue 2477703002: Remove now unused Balsa code. (Closed)
Patch Set: Rebase Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/tools/balsa/balsa_headers_test.cc ('k') | net/tools/balsa/balsa_headers_token_utils.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/balsa/balsa_headers_token_utils.h
diff --git a/net/tools/balsa/balsa_headers_token_utils.h b/net/tools/balsa/balsa_headers_token_utils.h
deleted file mode 100644
index aaa0e30cec5fd0d87edfec80e5669c6ed9023d1c..0000000000000000000000000000000000000000
--- a/net/tools/balsa/balsa_headers_token_utils.h
+++ /dev/null
@@ -1,61 +0,0 @@
-// Copyright 2013 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-// Utility class that performs basic operations on header value tokens: parsing
-// them out, checking for presense of certain tokens, and removing them.
-
-#ifndef NET_TOOLS_BALSA_BALSA_HEADERS_TOKEN_UTILS_H_
-#define NET_TOOLS_BALSA_BALSA_HEADERS_TOKEN_UTILS_H_
-
-#include "base/strings/string_piece.h"
-#include "net/tools/balsa/balsa_headers.h"
-
-namespace net {
-
-class BalsaHeadersTokenUtils {
- public:
- // All the functions below respect multiple header lines with the same key.
-
- // Checks whether the last header token matches a given value. Useful to
- // check the outer-most content or transfer-encoding, for example. In the
- // presence of multiple header lines with given key, the last token of the
- // last line is compared.
- static bool CheckHeaderForLastToken(const BalsaHeaders& headers,
- const base::StringPiece& key,
- const base::StringPiece& token);
-
- // Tokenizes header value for a given key. In the presence of multiple lines
- // with that key, all of them will be tokenized and tokens will be added to
- // the list in the order in which they are encountered.
- static void TokenizeHeaderValue(const BalsaHeaders& headers,
- const base::StringPiece& key,
- BalsaHeaders::HeaderTokenList* tokens);
-
- // Removes the last token from the header value. In the presence of multiple
- // header lines with given key, will remove the last token of the last line.
- // Can be useful if the last encoding has to be removed.
- static void RemoveLastTokenFromHeaderValue(const base::StringPiece& key,
- BalsaHeaders* headers);
-
- // Given a pointer to the beginning and the end of the header value
- // in some buffer, populates tokens list with beginning and end indices
- // of all tokens present in the value string.
- static void ParseTokenList(const char* start,
- const char* end,
- BalsaHeaders::HeaderTokenList* tokens);
-
- private:
- // Helper function to tokenize a header line once we have its description.
- static void TokenizeHeaderLine(
- const BalsaHeaders& headers,
- const BalsaHeaders::HeaderLineDescription& line,
- BalsaHeaders::HeaderTokenList* tokens);
-
- BalsaHeadersTokenUtils(); // Prohibit instantiation
-};
-
-} // namespace net
-
-#endif // NET_TOOLS_BALSA_BALSA_HEADERS_TOKEN_UTILS_H_
-
« no previous file with comments | « net/tools/balsa/balsa_headers_test.cc ('k') | net/tools/balsa/balsa_headers_token_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698