summaryrefslogtreecommitdiffstats
path: root/ppapi/cpp/private/net_address_private.h
diff options
context:
space:
mode:
authorsergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-22 22:41:06 +0000
committersergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-22 22:41:06 +0000
commitb13deef887384a4d8ff51ff6027128d0ffeeacfc (patch)
treea62578ff4d767ccc81657c50d97514086ec3c311 /ppapi/cpp/private/net_address_private.h
parentf497f0c6437d077911e6569789616754528e8a51 (diff)
downloadchromium_src-b13deef887384a4d8ff51ff6027128d0ffeeacfc.zip
chromium_src-b13deef887384a4d8ff51ff6027128d0ffeeacfc.tar.gz
chromium_src-b13deef887384a4d8ff51ff6027128d0ffeeacfc.tar.bz2
Add CreateFromIPv[46]Address() in PPB_NetAddress_Private.
Review URL: http://codereview.chromium.org/9722008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@128322 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi/cpp/private/net_address_private.h')
-rw-r--r--ppapi/cpp/private/net_address_private.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/ppapi/cpp/private/net_address_private.h b/ppapi/cpp/private/net_address_private.h
index c242175..5ad50d7 100644
--- a/ppapi/cpp/private/net_address_private.h
+++ b/ppapi/cpp/private/net_address_private.h
@@ -26,12 +26,21 @@ class NetAddressPrivate {
static bool ReplacePort(const PP_NetAddress_Private& addr_in,
uint16_t port,
PP_NetAddress_Private* addr_out);
- static void GetAnyAddress(bool is_ipv6, PP_NetAddress_Private* addr);
+ static bool GetAnyAddress(bool is_ipv6, PP_NetAddress_Private* addr);
static PP_NetAddressFamily_Private GetFamily(
const PP_NetAddress_Private& addr);
static uint16_t GetPort(const PP_NetAddress_Private& addr);
static bool GetAddress(const PP_NetAddress_Private& addr,
- void* address, uint16_t address_size);
+ void* address,
+ uint16_t address_size);
+ static uint32_t GetScopeID(const PP_NetAddress_Private& addr);
+ static bool CreateFromIPv4Address(const uint8_t ip[4],
+ uint16_t port,
+ struct PP_NetAddress_Private* addr_out);
+ static bool CreateFromIPv6Address(const uint8_t ip[16],
+ uint32_t scope_id,
+ uint16_t port,
+ struct PP_NetAddress_Private* addr_out);
};
} // namespace pp