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

Unified Diff: third_party/WebKit/Source/platform/network/HTTPParsers.h

Issue 2254533002: [FeaturePolicy] Initial implementation of Feature Policy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@fp-flag
Patch Set: Addressing nits 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
Index: third_party/WebKit/Source/platform/network/HTTPParsers.h
diff --git a/third_party/WebKit/Source/platform/network/HTTPParsers.h b/third_party/WebKit/Source/platform/network/HTTPParsers.h
index 6c84e4aca6979e1e91c5efe5c087231321c9afa9..681f1407577ee11af942769bce2edf7c8f587807 100644
--- a/third_party/WebKit/Source/platform/network/HTTPParsers.h
+++ b/third_party/WebKit/Source/platform/network/HTTPParsers.h
@@ -32,12 +32,15 @@
#define HTTPParsers_h
#include "platform/PlatformExport.h"
+#include "platform/json/JSONValues.h"
#include "wtf/Allocator.h"
#include "wtf/Forward.h"
#include "wtf/HashSet.h"
#include "wtf/Vector.h"
#include "wtf/text/StringHash.h"
+#include <memory>
+
namespace blink {
class Suborigin;
@@ -157,6 +160,12 @@ PLATFORM_EXPORT bool parseMultipartHeadersFromBody(const char* bytes,
ResourceResponse*,
size_t* end);
+// Parses a header value containing JSON data, according to
+// https://tools.ietf.org/html/draft-ietf-httpbis-jfv-01
+// Returns an empty unique_ptr if the header cannot be parsed as JSON.
+PLATFORM_EXPORT std::unique_ptr<JSONArray> parseJSONHeader(
+ const String& header);
+
} // namespace blink
#endif
« no previous file with comments | « third_party/WebKit/Source/platform/network/HTTPNames.in ('k') | third_party/WebKit/Source/platform/network/HTTPParsers.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698