7#ifndef LOCALIZED_OPTION_H 
    8#define LOCALIZED_OPTION_H 
   54                    const size_t offset = 0) :
 
   56        offset_(offset), option_valid_(true) {
 
 
   74                    const size_t offset = 0) :
 
   76        offset_(offset), option_valid_(true) {
 
 
   88                    const size_t offset) :
 
   90        offset_(offset), option_valid_(false) {
 
   97            type_ = opt_ia->getType();
 
  103                    const uint8_t* buf_data = buf.
getData();
 
  109                option_valid_ = 
true;
 
  114                option_valid_ = 
false;
 
  117            option_valid_ = 
false;
 
 
  130        return (Option::valid() && option_valid_);
 
 
 
This is a base class for exceptions thrown from the DNS library module.
uint16_t type_
option type (0-255 for DHCPv4, 0-65535 for DHCPv6)
Universe
defines option universe DHCPv4 or DHCPv6
Universe universe_
option universe (V4 or V6)
OptionBuffer data_
contains content of this data
Option(Universe u, uint16_t type)
ctor, used for options constructed, usually during transmission
LocalizedOption(const boost::shared_ptr< dhcp::Option6IA > &opt_ia, const size_t offset)
Copy constructor, creates LocalizedOption from Option6IA.
LocalizedOption(dhcp::Option::Universe u, uint16_t type, const dhcp::OptionBuffer &data, const size_t offset=0)
Constructor, used to create localized option from buffer.
LocalizedOption(dhcp::Option::Universe u, uint16_t type, dhcp::OptionBufferConstIter first, dhcp::OptionBufferConstIter last, const size_t offset=0)
Constructor, used to create option from buffer iterators.
virtual bool valid() const
Checks if option is valid.
size_t getOffset() const
Returns offset of an option in a DHCP packet.
The OutputBuffer class is a buffer abstraction for manipulating mutable data.
const uint8_t * getData() const
Return a pointer to the head of the data stored in the buffer.
size_t getLength() const
Return the length of data written in the buffer.
OptionBuffer::const_iterator OptionBufferConstIter
const_iterator for walking over OptionBuffer
std::vector< uint8_t > OptionBuffer
buffer types used in DHCP code.
Defines the logger used by the top-level component of kea-lfc.