asio C++ library

PrevUpHomeNext

ip::address_cast

Cast a version-independent address to itself.

template<
    typename T>
T address_cast(
    const address & addr,
    typename enable_if< is_same< T, address >::value >::type *  = 0);
  » more...

template<
    typename T>
T address_cast(
    const address & addr,
    typename enable_if< is_same< T, address_v4 >::value >::type *  = 0);
  » more...

template<
    typename T>
T address_cast(
    const address & addr,
    typename enable_if< is_same< T, address_v6 >::value >::type *  = 0);
  » more...

template<
    typename T>
T address_cast(
    const address_v4 & addr,
    typename enable_if< is_same< T, address >::value >::type *  = 0);
  » more...

template<
    typename T>
T address_cast(
    const address_v4 & addr,
    typename enable_if< is_same< T, address_v4 >::value >::type *  = 0);
  » more...

template<
    typename T>
bad_address_cast address_cast(
    const address_v4 & ,
    typename enable_if< is_same< T, address_v6 >::value >::type *  = 0);
  » more...

template<
    typename T>
T address_cast(
    const address_v6 & addr,
    typename enable_if< is_same< T, address >::value >::type *  = 0);
  » more...

template<
    typename T>
T address_cast(
    const address_v6 & addr,
    typename enable_if< is_same< T, address_v6 >::value >::type *  = 0);
  » more...

template<
    typename T>
bad_address_cast address_cast(
    const address_v6 & ,
    typename enable_if< is_same< T, address_v4 >::value >::type *  = 0);
  » more...
Requirements

Header: asio/ip/address.hpp

Convenience header: asio.hpp


PrevUpHomeNext