OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef PPAPI_PROXY_RESOURCE_MESSAGE_PARAMS_H_ | 5 #ifndef PPAPI_PROXY_RESOURCE_MESSAGE_PARAMS_H_ |
6 #define PPAPI_PROXY_RESOURCE_MESSAGE_PARAMS_H_ | 6 #define PPAPI_PROXY_RESOURCE_MESSAGE_PARAMS_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 }; | 179 }; |
180 | 180 |
181 } // namespace proxy | 181 } // namespace proxy |
182 } // namespace ppapi | 182 } // namespace ppapi |
183 | 183 |
184 namespace IPC { | 184 namespace IPC { |
185 | 185 |
186 template <> struct PPAPI_PROXY_EXPORT | 186 template <> struct PPAPI_PROXY_EXPORT |
187 ParamTraits<ppapi::proxy::ResourceMessageCallParams> { | 187 ParamTraits<ppapi::proxy::ResourceMessageCallParams> { |
188 typedef ppapi::proxy::ResourceMessageCallParams param_type; | 188 typedef ppapi::proxy::ResourceMessageCallParams param_type; |
189 static void Write(Message* m, const param_type& p) { | 189 static void Write(base::Pickle* m, const param_type& p) { |
190 p.Serialize(m); | 190 p.Serialize(static_cast<IPC::Message*>(m)); |
191 } | 191 } |
192 static bool Read(const Message* m, base::PickleIterator* iter, | 192 static bool Read(const base::Pickle* m, |
| 193 base::PickleIterator* iter, |
193 param_type* r) { | 194 param_type* r) { |
194 return r->Deserialize(m, iter); | 195 return r->Deserialize(static_cast<const IPC::Message*>(m), iter); |
195 } | 196 } |
196 static void Log(const param_type& p, std::string* l) { | 197 static void Log(const param_type& p, std::string* l) { |
197 } | 198 } |
198 }; | 199 }; |
199 | 200 |
200 template <> struct PPAPI_PROXY_EXPORT | 201 template <> struct PPAPI_PROXY_EXPORT |
201 ParamTraits<ppapi::proxy::ResourceMessageReplyParams> { | 202 ParamTraits<ppapi::proxy::ResourceMessageReplyParams> { |
202 typedef ppapi::proxy::ResourceMessageReplyParams param_type; | 203 typedef ppapi::proxy::ResourceMessageReplyParams param_type; |
203 static void Write(Message* m, const param_type& p) { | 204 static void Write(base::Pickle* m, const param_type& p) { |
204 p.Serialize(m); | 205 p.Serialize(static_cast<IPC::Message*>(m)); |
205 } | 206 } |
206 static bool Read(const Message* m, base::PickleIterator* iter, | 207 static bool Read(const base::Pickle* m, |
| 208 base::PickleIterator* iter, |
207 param_type* r) { | 209 param_type* r) { |
208 return r->Deserialize(m, iter); | 210 return r->Deserialize(static_cast<const IPC::Message*>(m), iter); |
209 } | 211 } |
210 static void Log(const param_type& p, std::string* l) { | 212 static void Log(const param_type& p, std::string* l) { |
211 } | 213 } |
212 }; | 214 }; |
213 | 215 |
214 } // namespace IPC | 216 } // namespace IPC |
215 | 217 |
216 #endif // PPAPI_PROXY_RESOURCE_MESSAGE_PARAMS_H_ | 218 #endif // PPAPI_PROXY_RESOURCE_MESSAGE_PARAMS_H_ |
OLD | NEW |