| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CONTENT_COMMON_INDEXED_DB_PARAM_TRAITS_H_ | |
| 6 #define CONTENT_COMMON_INDEXED_DB_PARAM_TRAITS_H_ | |
| 7 #pragma once | |
| 8 | |
| 9 #include "ipc/ipc_message.h" | |
| 10 #include "ipc/ipc_param_traits.h" | |
| 11 | |
| 12 class IndexedDBKey; | |
| 13 | |
| 14 namespace content { | |
| 15 class SerializedScriptValue; | |
| 16 } | |
| 17 | |
| 18 namespace IPC { | |
| 19 | |
| 20 // These datatypes are used by utility_messages.h and render_messages.h. | |
| 21 // Unfortunately we can't move it to common: MSVC linker complains about | |
| 22 // WebKit datatypes that are not linked on npchrome_frame (even though it's | |
| 23 // never actually used by that target). | |
| 24 | |
| 25 template <> | |
| 26 struct ParamTraits<content::SerializedScriptValue> { | |
| 27 typedef content::SerializedScriptValue param_type; | |
| 28 static void Write(Message* m, const param_type& p); | |
| 29 static bool Read(const Message* m, void** iter, param_type* r); | |
| 30 static void Log(const param_type& p, std::string* l); | |
| 31 }; | |
| 32 | |
| 33 template <> | |
| 34 struct ParamTraits<IndexedDBKey> { | |
| 35 typedef IndexedDBKey param_type; | |
| 36 static void Write(Message* m, const param_type& p); | |
| 37 static bool Read(const Message* m, void** iter, param_type* r); | |
| 38 static void Log(const param_type& p, std::string* l); | |
| 39 }; | |
| 40 | |
| 41 } // namespace IPC | |
| 42 | |
| 43 #endif // CONTENT_COMMON_INDEXED_DB_PARAM_TRAITS_H_ | |
| OLD | NEW |