12#include <boost/foreach.hpp> 
   29    host->contextToElement(map);
 
   39        const vector<uint8_t>& bin = host->getIdentifier();
 
   43        const vector<uint8_t>& bin = host->getIdentifier();
 
   47        const vector<uint8_t>& bin = host->getIdentifier();
 
   55    const IOAddress& address = host->getIPv4Reservation();
 
   63    BOOST_FOREACH(
auto const& resv, na_resv) {
 
   66    if (resvs->size() > 0) {
 
   67        map->set(
"ip-addresses", resvs);
 
   72    BOOST_FOREACH(
auto const& resv, pd_resv) {
 
   75    if (resvs->size() > 0) {
 
   76        map->set(
"prefixes", resvs);
 
   80    const string& hostname = host->getHostname();
 
   84    const IOAddress& next_server = host->getNextServer();
 
   87    const string& server_hostname = host->getServerHostname();
 
   90    const string& boot_file_name = host->getBootFileName();
 
   96    for (
auto const& cclass : cclasses4) {
 
   99    map->set(
"client-classes4", classes);
 
  103    for (
auto const& cclass : cclasses6) {
 
  106    map->set(
"client-classes6", classes);
 
  110    map->set(
"option-data4", opts->toElement());
 
  112    opts = host->getCfgOption6();
 
  113    map->set(
"option-data6", opts->toElement());
 
  116    SubnetID subnet_id = host->getIPv4SubnetID();
 
  117    map->set(
"subnet-id4", 
Element::create(
static_cast<long long>(subnet_id)));
 
  119    subnet_id = host->getIPv6SubnetID();
 
  120    map->set(
"subnet-id6", 
Element::create(
static_cast<long long>(subnet_id)));
 
  123    uint64_t hid = host->getHostId();
 
  127    if (host->getNegative()) {
 
 
static ElementPtr create(const Position &pos=ZERO_POSITION())
static ElementPtr createMap(const Position &pos=ZERO_POSITION())
Creates an empty MapElement type ElementPtr.
static ElementPtr createList(const Position &pos=ZERO_POSITION())
Creates an empty ListElement type ElementPtr.
The IOAddress class represents an IP addresses (version agnostic)
bool isV4Zero() const
Convenience function to check if it is an IPv4 zero address.
std::string toText() const
Convert the address to a string.
Container for storing client class names.
IdentifierType
Type of the host identifier.
@ IDENT_FLEX
Flexible host identifier.
#define isc_throw(type, stream)
A shortcut macro to insert known values into exception arguments.
boost::shared_ptr< Element > ElementPtr
boost::shared_ptr< DUID > DuidPtr
std::pair< IPv6ResrvIterator, IPv6ResrvIterator > IPv6ResrvRange
boost::shared_ptr< HWAddr > HWAddrPtr
Shared pointer to a hardware address structure.
uint32_t SubnetID
Defines unique IPv4 or IPv6 subnet identifier.
boost::shared_ptr< const Host > ConstHostPtr
Const pointer to the Host object.
boost::shared_ptr< const CfgOption > ConstCfgOptionPtr
Const pointer.
ElementPtr toElement(const ConstHostPtr &host)
Unparse a host cache entry.
string encodeHex(const vector< uint8_t > &binary)
Encode binary data in the base16 format.
Defines the logger used by the top-level component of kea-lfc.