blob: af1c9e0e2a49c0d8da4390a6fddc1d869d554f66 [file] [log] [blame]
[email protected]d38c57402011-03-11 20:20:561// Copyright (c) 2011 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 PPAPI_PROXY_PPB_CONSOLE_PROXY_H_
6#define PPAPI_PROXY_PPB_CONSOLE_PROXY_H_
7
8#include "base/basictypes.h"
9#include "ppapi/c/pp_instance.h"
10#include "ppapi/proxy/interface_proxy.h"
11#include "ppapi/proxy/serialized_var.h"
12
13struct PPB_Console_Dev;
14
15namespace pp {
16namespace proxy {
17
18class PPB_Console_Proxy : public InterfaceProxy {
19 public:
20 PPB_Console_Proxy(Dispatcher* dispatcher, const void* target_interface);
21 virtual ~PPB_Console_Proxy();
22
23 static const Info* GetInfo();
24
25 const PPB_Console_Dev* ppb_console_target() const {
26 return static_cast<const PPB_Console_Dev*>(target_interface());
27 }
28
29 // InterfaceProxy implementation.
30 virtual bool OnMessageReceived(const IPC::Message& msg);
31
32 private:
33 // Message handlers.
34 void OnMsgLog(PP_Instance instance,
35 int log_level,
36 SerializedVarReceiveInput value);
37 void OnMsgLogWithSource(PP_Instance instance,
38 int log_level,
39 SerializedVarReceiveInput source,
40 SerializedVarReceiveInput value);
41
42 DISALLOW_COPY_AND_ASSIGN(PPB_Console_Proxy);
43};
44
45} // namespace proxy
46} // namespace pp
47
48#endif // PPAPI_PROXY_PPB_CONSOLE_PROXY_H_