uvcc
libuv C++ bindings

Functions

template<typename _I_ >
uint16_t uv::hton16 (const _I_ &_i)
 Cross-platform htons()
 
template<typename _I_ >
uint32_t uv::hton32 (const _I_ &_i)
 Cross-platform htonl()
 
template<typename _I_ >
uint64_t uv::hton64 (const _I_ &_i)
 Cross-platform htonll()
 
template<typename _I_ >
uint16_t uv::ntoh16 (const _I_ &_i)
 Cross-platform ntohs()
 
template<typename _I_ >
uint32_t uv::ntoh32 (const _I_ &_i)
 Cross-platform ntohl()
 
template<typename _I_ >
uint64_t uv::ntoh64 (const _I_ &_i)
 Cross-platform ntohll()
 

Detailed Description

Templates of cross-platform (Windows/Unix-like systems) functions for byte order conversion between host and network byte encoding.

See also
For fairly complete version of C functions see e.g.:
https://gist.github.com/panzi/6856583
https://github.com/blizzard4591/cmake-portable-endian