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.
5 #ifndef PPAPI_PROXY_HOST_RESOLVER_PRIVATE_RESOURCE_H_
6 #define PPAPI_PROXY_HOST_RESOLVER_PRIVATE_RESOURCE_H_
8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h"
10 #include "ppapi/proxy/host_resolver_resource_base.h"
11 #include "ppapi/proxy/ppapi_proxy_export.h"
12 #include "ppapi/thunk/ppb_host_resolver_private_api.h"
17 class PPAPI_PROXY_EXPORT HostResolverPrivateResource
18 : public HostResolverResourceBase
,
19 public thunk::PPB_HostResolver_Private_API
{
21 HostResolverPrivateResource(Connection connection
,
22 PP_Instance instance
);
23 virtual ~HostResolverPrivateResource();
25 // PluginResource overrides.
26 virtual thunk::PPB_HostResolver_Private_API
*
27 AsPPB_HostResolver_Private_API() override
;
29 // PPB_HostResolver_Private_API implementation.
30 virtual int32_t Resolve(const char* host
,
32 const PP_HostResolver_Private_Hint
* hint
,
33 scoped_refptr
<TrackedCallback
> callback
) override
;
34 virtual PP_Var
GetCanonicalName() override
;
35 virtual uint32_t GetSize() override
;
36 virtual bool GetNetAddress(uint32_t index
,
37 PP_NetAddress_Private
* address
) override
;
40 DISALLOW_COPY_AND_ASSIGN(HostResolverPrivateResource
);
46 #endif // PPAPI_PROXY_HOST_RESOLVER_PRIVATE_RESOURCE_H_