cc: Added inline to Tile::IsReadyToDraw
[chromium-blink-merge.git] / ppapi / thunk / ppb_tcp_socket_api.h
blobd33685fd97fff92f96bfc37e6ec5af6c4851127a
1 // Copyright 2013 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.
5 #ifndef PPAPI_THUNK_PPB_TCP_SOCKET_API_H_
6 #define PPAPI_THUNK_PPB_TCP_SOCKET_API_H_
8 #include "base/memory/ref_counted.h"
9 #include "ppapi/c/ppb_tcp_socket.h"
10 #include "ppapi/thunk/ppapi_thunk_export.h"
12 namespace ppapi {
14 class TrackedCallback;
16 namespace thunk {
18 class PPAPI_THUNK_EXPORT PPB_TCPSocket_API {
19 public:
20 virtual ~PPB_TCPSocket_API() {}
22 virtual int32_t Connect(PP_Resource addr,
23 scoped_refptr<TrackedCallback> callback) = 0;
24 virtual PP_Resource GetLocalAddress() = 0;
25 virtual PP_Resource GetRemoteAddress() = 0;
26 virtual int32_t Read(char* buffer,
27 int32_t bytes_to_read,
28 scoped_refptr<TrackedCallback> callback) = 0;
29 virtual int32_t Write(const char* buffer,
30 int32_t bytes_to_write,
31 scoped_refptr<TrackedCallback> callback) = 0;
32 virtual void Close() = 0;
33 virtual int32_t SetOption(PP_TCPSocket_Option name,
34 const PP_Var& value,
35 scoped_refptr<TrackedCallback> callback) = 0;
38 } // namespace thunk
39 } // namespace ppapi
41 #endif // PPAPI_THUNK_PPB_TCP_SOCKET_API_H_