OLD | NEW |
---|---|
(Empty) | |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef PPAPI_CPP_PRIVATE_TCP_SERVER_SOCKET_PRIVATE_H_ | |
6 #define PPAPI_CPP_PRIVATE_TCP_SERVER_SOCKET_PRIVATE_H_ | |
7 | |
8 #include "ppapi/c/pp_stdint.h" | |
9 #include "ppapi/c/private/ppb_tcp_server_socket_private.h" | |
10 #include "ppapi/cpp/resource.h" | |
11 | |
12 namespace pp { | |
13 | |
14 class CompletionCallback; | |
15 class InstanceHandle; | |
16 | |
17 class TCPServerSocketPrivate : public Resource { | |
18 public: | |
19 explicit TCPServerSocketPrivate(const InstanceHandle& instance); | |
20 | |
21 // Returns true if the required interface is available. | |
22 static bool IsAvailable(); | |
brettw
2012/03/05 18:30:50
We don't normally add this type of function for re
yzshen1
2012/03/05 18:53:13
It is used to ease Pepper Flash developing:
Usual
brettw
2012/03/05 21:30:42
I guess I'd say we shouldn't bother with this func
yzshen1
2012/03/05 22:49:27
Resource creation could fail because of other reas
ygorshenin1
2012/03/06 11:37:52
IsAvailable is deleted.
On 2012/03/05 22:49:27, y
viettrungluu
2012/03/06 18:31:49
I stipulate that if it's at all plausible that the
ygorshenin1
2012/03/07 11:17:29
OK, I restored this method.
On 2012/03/06 18:31:4
| |
23 | |
24 int32_t Listen(const PP_NetAddress_Private* addr, | |
25 int32_t backlog, | |
26 const CompletionCallback& callback); | |
27 int32_t Accept(PP_Resource* socket, | |
yzshen1
2012/03/05 18:53:13
- How about returning a cpp wrapper object?
int32_
ygorshenin1
2012/03/06 11:37:52
- This is possible, but will greatly complicate th
yzshen1
2012/03/06 19:08:41
Please be noted that there is not a proper constru
ygorshenin1
2012/03/07 11:17:29
Thanks for explaining, Done.
| |
28 const CompletionCallback& callback); | |
29 void StopListening(); | |
30 }; | |
31 | |
32 } // namespace pp | |
33 | |
34 #endif // PPAPI_CPP_PRIVATE_TCP_SERVER_SOCKET_PRIVATE_H_ | |
OLD | NEW |