32    for (
auto const& header : headers) {
 
   33        list->add(header.toElement());
 
 
   52        isc_throw(DhcpConfigError, 
"null 'http-headers' item");
 
   55        isc_throw(DhcpConfigError, 
"invalid type specified for 'http-headers' " 
   56                  "item (" << config->getPosition() << 
")");
 
   60    string name = config->get(
"name")->stringValue();
 
   62        isc_throw(DhcpConfigError, 
"empty 'name' parameter (" 
   63                  << config->get(
"name")->getPosition() << 
")");
 
   65    string value = config->get(
"value")->stringValue();
 
   67        isc_throw(DhcpConfigError, 
"empty 'value' parameter (" 
   68                  << config->get(
"value")->getPosition() << 
")");
 
   73        header.setContext(user_context);
 
   88                  "'http-headers' (" << 
config->getPosition() << 
")");
 
   90    for (
auto const& item : 
config->listValue()) {
 
   91        headers.push_back(parseCfgHttpHeader(item));
 
 
static ElementPtr create(const Position &pos=ZERO_POSITION())
static ElementPtr createList(const Position &pos=ZERO_POSITION())
Creates an empty ListElement type ElementPtr.
static ElementPtr createMap(const Position &pos=ZERO_POSITION())
Creates an empty MapElement type ElementPtr.
static void checkKeywords(const SimpleKeywords &keywords, isc::data::ConstElementPtr scope)
Checks acceptable keywords with their expected type.
static void checkRequired(const SimpleRequiredKeywords &required, isc::data::ConstElementPtr scope)
Checks that all required keywords are present.
To be removed. Please use ConfigError instead.
#define isc_throw(type, stream)
A shortcut macro to insert known values into exception arguments.
std::vector< std::string > SimpleRequiredKeywords
This specifies all required keywords.
boost::shared_ptr< const Element > ConstElementPtr
boost::shared_ptr< Element > ElementPtr
std::map< std::string, isc::data::Element::types > SimpleKeywords
This specifies all accepted keywords with their types.
ElementPtr CfgHttpHeaderstoElement(const CfgHttpHeaders &headers)
Unparse config HTTP headers.
CfgHttpHeaders parseCfgHttpHeaders(const ConstElementPtr &config)
Parse config HTTP headers.
std::vector< CfgHttpHeader > CfgHttpHeaders
Collection of config HTTP headers.
Defines the logger used by the top-level component of kea-lfc.
void contextToElement(data::ElementPtr map) const
Merge unparse a user_context object.