예제 #1
0
/**
 * Get the station interface IPv6 address.
 * @return IPv6Address
 */
IPv6Address WiFiSTAClass::localIPv6()
{
    static ip6_addr_t addr;
    if(tcpip_adapter_get_ip6_linklocal(TCPIP_ADAPTER_IF_STA, &addr)){
        return IPv6Address();
    }
    return IPv6Address(addr.addr);
}
IPv6Address IPv6Address::operator ^(const IPv6Address& address) const
{
    std::vector< uint8_t > bytes;
    for( int i = 0; i < IPv6AddressSize; ++i )
    {
        bytes.push_back( address_[i] ^ address.address_[i] );
    }
    return IPv6Address( bytes );
}