diff options
Diffstat (limited to 'ppapi/proxy/ppapi_param_traits.h')
-rw-r--r-- | ppapi/proxy/ppapi_param_traits.h | 108 |
1 files changed, 72 insertions, 36 deletions
diff --git a/ppapi/proxy/ppapi_param_traits.h b/ppapi/proxy/ppapi_param_traits.h index e3638b8..6996547 100644 --- a/ppapi/proxy/ppapi_param_traits.h +++ b/ppapi/proxy/ppapi_param_traits.h @@ -49,24 +49,30 @@ namespace IPC { template<> struct PPAPI_PROXY_EXPORT ParamTraits<PP_Bool> { typedef PP_Bool param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template <> struct PPAPI_PROXY_EXPORT ParamTraits<PP_NetAddress_Private> { typedef PP_NetAddress_Private param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* p); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* p); static void Log(const param_type& p, std::string* l); }; template <> struct PPAPI_PROXY_EXPORT ParamTraits<PP_KeyInformation> { typedef PP_KeyInformation param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* p); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* p); static void Log(const param_type& p, std::string* l); }; @@ -74,8 +80,10 @@ template<> struct PPAPI_PROXY_EXPORT ParamTraits< ppapi::proxy::PPBFlash_DrawGlyphs_Params> { typedef ppapi::proxy::PPBFlash_DrawGlyphs_Params param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; @@ -83,24 +91,30 @@ template<> struct PPAPI_PROXY_EXPORT ParamTraits< ppapi::proxy::PPBURLLoader_UpdateProgress_Params> { typedef ppapi::proxy::PPBURLLoader_UpdateProgress_Params param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::proxy::SerializedDirEntry> { typedef ppapi::proxy::SerializedDirEntry param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::proxy::SerializedFontDescription> { typedef ppapi::proxy::SerializedFontDescription param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; @@ -108,32 +122,40 @@ template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::proxy::SerializedTrueTypeFontDesc> { typedef ppapi::proxy::SerializedTrueTypeFontDesc param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::proxy::SerializedHandle> { typedef ppapi::proxy::SerializedHandle param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::HostResource> { typedef ppapi::HostResource param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::proxy::SerializedVar> { typedef ppapi::proxy::SerializedVar param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; @@ -141,16 +163,20 @@ template<> struct PPAPI_PROXY_EXPORT ParamTraits< std::vector<ppapi::proxy::SerializedVar> > { typedef std::vector<ppapi::proxy::SerializedVar> param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::PpapiPermissions> { typedef ppapi::PpapiPermissions param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; @@ -158,16 +184,20 @@ struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::PpapiPermissions> { template <> struct ParamTraits<ppapi::PepperFilePath> { typedef ppapi::PepperFilePath param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* p); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* p); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::proxy::SerializedFlashMenu> { typedef ppapi::proxy::SerializedFlashMenu param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; #endif // !defined(OS_NACL) && !defined(NACL_WIN64) @@ -175,24 +205,30 @@ struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::proxy::SerializedFlashMenu> { template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::PPB_X509Certificate_Fields> { typedef ppapi::PPB_X509Certificate_Fields param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::SocketOptionData> { typedef ppapi::SocketOptionData param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; template<> struct PPAPI_PROXY_EXPORT ParamTraits<ppapi::CompositorLayerData::Transform> { typedef ppapi::CompositorLayerData::Transform param_type; - static void Write(Message* m, const param_type& p); - static bool Read(const Message* m, base::PickleIterator* iter, param_type* r); + static void Write(base::Pickle* m, const param_type& p); + static bool Read(const base::Pickle* m, + base::PickleIterator* iter, + param_type* r); static void Log(const param_type& p, std::string* l); }; |