6 #ifndef vnsw_agent_oper_dhcp_options_h_
7 #define vnsw_agent_oper_dhcp_options_h_
9 #include <vnc_cfg_types.h>
12 struct DhcpOptionType;
41 snprintf(len,
sizeof(len),
"%u",
plen_);
42 return prefix_.to_string() +
"/" + std::string(len) +
43 " -> " +
gw_.to_string();
63 for (
unsigned int i = 0; i <
host_routes.size(); ++i) {
67 (
int *)&host_route.
plen_);
68 if (ec || host_route.
plen_ > 32) {
71 host_route.
gw_ = Ip4Address::from_string(
host_routes[i].next_hop, ec);
boost::system::error_code Ip4PrefixParse(const string &str, Ip4Address *addr, int *plen)
boost::asio::ip::address_v4 Ip4Address
bool are_dhcp_options_set() const
std::vector< autogen::RouteType > HostOptionsList
void set_options(const DhcpOptionsList &options)
std::vector< HostRoute > host_routes_
DhcpOptionsList dhcp_options_
virtual ~OperDhcpOptions()
OperDhcpOptions(const OperDhcpOptions &options)
std::vector< autogen::DhcpOptionType > DhcpOptionsList
void set_host_routes(const HostOptionsList &host_routes)
const std::vector< HostRoute > & host_routes() const
const DhcpOptionsList & dhcp_options() const
bool are_host_routes_set() const
void update_host_routes(const HostOptionsList &host_routes)
bool operator<(const HostRoute &rhs) const
std::string ToString() const
bool operator==(const HostRoute &rhs) const