Android-cuttlefish cvd tool
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
ServiceInfo Struct Reference

#include <discovered_services.h>

Public Member Functions

 ServiceInfo ()=default
 
 ServiceInfo (const std::string &in_instance, const std::string &in_service, const std::string &hostname, const std::optional< IPv4Address > &in_v4_address, const std::unordered_set< IPv6Address, IPv6AddressHash > &in_v6_addresses, const uint16_t in_port, const std::vector< std::vector< uint8_t > > &txt)
 
std::string v4_address_string () const
 

Static Public Member Functions

static std::tuple< bool, std::string, std::string > ParseTxtKeyValue (const std::string &kv)
 
static std::unordered_map< std::string, std::string > ParseTxt (const std::vector< std::vector< uint8_t > > &txt)
 

Public Attributes

std::string instance
 
std::string service
 
std::string hostname
 
std::optional< IPv4Address > v4_address
 
std::unordered_set< IPv6Address, IPv6AddressHash > v6_addresses
 
uint16_t port
 
std::unordered_map< std::string, std::string > attributes
 

Constructor & Destructor Documentation

◆ ServiceInfo() [1/2]

ServiceInfo::ServiceInfo ( )
default

◆ ServiceInfo() [2/2]

ServiceInfo::ServiceInfo ( const std::string &  in_instance,
const std::string &  in_service,
const std::string &  hostname,
const std::optional< IPv4Address > &  in_v4_address,
const std::unordered_set< IPv6Address, IPv6AddressHash > &  in_v6_addresses,
const uint16_t  in_port,
const std::vector< std::vector< uint8_t > > &  txt 
)
inline

Member Function Documentation

◆ ParseTxt()

std::unordered_map< std::string, std::string > ServiceInfo::ParseTxt ( const std::vector< std::vector< uint8_t > > &  txt)
static

◆ ParseTxtKeyValue()

std::tuple< bool, std::string, std::string > ServiceInfo::ParseTxtKeyValue ( const std::string &  kv)
static

◆ v4_address_string()

std::string ServiceInfo::v4_address_string ( ) const
inline

Member Data Documentation

◆ attributes

std::unordered_map<std::string, std::string> ServiceInfo::attributes

◆ hostname

std::string ServiceInfo::hostname

◆ instance

std::string ServiceInfo::instance

◆ port

uint16_t ServiceInfo::port

◆ service

std::string ServiceInfo::service

◆ v4_address

std::optional<IPv4Address> ServiceInfo::v4_address

◆ v6_addresses

std::unordered_set<IPv6Address, IPv6AddressHash> ServiceInfo::v6_addresses

The documentation for this struct was generated from the following files: