#include <exceptions/exceptions.h>
#include <dhcpsrv/subnet.h>
#include <util/optional_value.h>
+#include <boost/shared_ptr.hpp>
namespace isc {
namespace dhcp {
};
+/// @name Pointer to the @c CfgSubnets4 objects.
+//@{
+/// @brief Non-const pointer.
+typedef boost::shared_ptr<CfgSubnets4> CfgSubnets4Ptr;
+
+/// @brief Const pointer.
+typedef boost::shared_ptr<const CfgSubnets4> ConstCfgSubnets4Ptr;
+
+//@}
+
}
}
SrvConfig::SrvConfig()
: sequence_(0), cfg_option_def_(new CfgOptionDef()),
- cfg_option_(new CfgOption()) {
+ cfg_option_(new CfgOption()), cfg_subnets4_(new CfgSubnets4()) {
}
SrvConfig::SrvConfig(const uint32_t sequence)
: sequence_(sequence), cfg_option_def_(new CfgOptionDef()),
- cfg_option_(new CfgOption()) {
+ cfg_option_(new CfgOption()), cfg_subnets4_(new CfgSubnets4()) {
}
std::string
#include <dhcpsrv/cfg_iface.h>
#include <dhcpsrv/cfg_option.h>
#include <dhcpsrv/cfg_option_def.h>
+#include <dhcpsrv/cfg_subnets4.h>
#include <dhcpsrv/logging_info.h>
#include <boost/shared_ptr.hpp>
#include <vector>
return (cfg_option_);
}
+ /// @brief Returns pointer to non-const object holding subnets configuration
+ /// for DHCPv4.
+ ///
+ /// @return Pointer to the object holding subnets configuration for DHCPv4.
+ CfgSubnets4Ptr getCfgSubnets4() {
+ return (cfg_subnets4_);
+ }
+
+ /// @brief Returns pointer to const object holding subnets configuration for
+ /// DHCPv4.
+ ///
+ /// @return Pointer to the object holding subnets configuration for DHCPv4.
+ ConstCfgSubnets4Ptr getCfgSubnets4() const {
+ return (cfg_subnets4_);
+ }
+
//@}
/// @brief Copies the currnet configuration to a new configuration.
/// connected to any subnet.
CfgOptionPtr cfg_option_;
+ /// @brief Pointer to subnets configuration for IPv4.
+ CfgSubnets4Ptr cfg_subnets4_;
+
};
/// @name Pointers to the @c SrvConfig object.