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

Unified Diff: content/common/page_state_serialization.h

Issue 1907443006: PlzNavigate: store POST data in the FrameNavigationEntry (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: content/common/page_state_serialization.h
diff --git a/content/common/page_state_serialization.h b/content/common/page_state_serialization.h
index 24d81981ef84bbba89f624f01e58163565e154a8..42b6f3074bb6cc7d63f47b3fd35732d148f14df5 100644
--- a/content/common/page_state_serialization.h
+++ b/content/common/page_state_serialization.h
@@ -12,6 +12,7 @@
#include "base/strings/nullable_string16.h"
#include "build/build_config.h"
#include "content/common/content_export.h"
+#include "content/common/resource_request_body.h"
#include "third_party/WebKit/public/platform/WebHTTPBody.h"
#include "third_party/WebKit/public/platform/WebHistoryScrollRestorationType.h"
#include "third_party/WebKit/public/platform/WebReferrerPolicy.h"
@@ -44,6 +45,7 @@ struct CONTENT_EXPORT ExplodedHttpBody {
bool is_null;
ExplodedHttpBody();
+ ExplodedHttpBody(const ExplodedHttpBody& other);
~ExplodedHttpBody();
};
@@ -88,6 +90,11 @@ CONTENT_EXPORT bool DecodePageState(const std::string& encoded,
CONTENT_EXPORT bool EncodePageState(const ExplodedPageState& exploded,
std::string* encoded);
+// If |exploded| is not null, initializes |http_body| with the data from
+// |exploded|. Returns false otherwise.
+bool GeneratePostData(const ExplodedHttpBody exploded,
+ ResourceRequestBody* http_body);
+
#if defined(OS_ANDROID)
CONTENT_EXPORT bool DecodePageStateWithDeviceScaleFactorForTesting(
const std::string& encoded,

Powered by Google App Engine
This is Rietveld 408576698