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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.h

Issue 2017543002: [Binding] [Refactoring] Make SerializedScriptValueWriter protected (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: writeNull() Created 4 years, 7 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.h b/third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.h
index 4eb6246855d435553cdc6113ba1aa75624bf735f..4a4700c9ff661a87d71808c6f7c6bd6833b3ef26 100644
--- a/third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.h
+++ b/third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.h
@@ -110,8 +110,13 @@ public:
{
}
- // Write functions for primitive types.
+ // TODO(peria): Protect this mehtod.
+ String takeWireString();
+
+protected:
+ friend class ScriptValueSerializer;
+ // Write functions for primitive types.
void writeUndefined();
void writeNull();
void writeTrue();
@@ -149,7 +154,6 @@ public:
void writeObject(uint32_t numProperties);
void writeSparseArray(uint32_t numProperties, uint32_t length);
void writeDenseArray(uint32_t numProperties, uint32_t length);
- String takeWireString();
void writeReferenceCount(uint32_t numberOfReferences);
void writeGenerateFreshObject();
void writeGenerateFreshSparseArray(uint32_t length);
@@ -159,7 +163,6 @@ public:
void writeMap(uint32_t length);
void writeSet(uint32_t length);
-protected:
void doWriteFile(const File&);
void doWriteArrayBuffer(const DOMArrayBuffer&);
void doWriteString(const char* data, int length);
@@ -216,6 +219,9 @@ public:
Status serialize(v8::Local<v8::Value>);
String errorMessage() { return m_errorMessage; }
+ static String serializeWTFString(const String&);
+ static String serializeNullValue();
+
protected:
class StateBase {
USING_FAST_MALLOC(StateBase);
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/core/v8/ScriptValueSerializer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698