8 #define ZONE_CHECKER_H 1
43 const IssueCallback& warn_callback) :
44 error_callback_(error_callback), warn_callback_(warn_callback)
53 void error(
const std::string& reason)
const {
54 if (error_callback_) {
55 error_callback_(reason);
65 void warn(
const std::string& reason)
const {
67 warn_callback_(reason);
71 IssueCallback error_callback_;
72 IssueCallback warn_callback_;
143 checkZone(
const Name& zone_name,
const RRClass& zone_class,
144 const RRsetCollectionBase& zone_rrsets,
145 const ZoneCheckerCallbacks& callbacks);
149 #endif // ZONE_CHECKER_H
bool checkZone(const Name &zone_name, const RRClass &zone_class, const RRsetCollectionBase &zone_rrsets, const ZoneCheckerCallbacks &callbacks)
Perform basic integrity checks on zone RRsets.
Set of callbacks used in zone checks.
std::function< void(const std::string &reason)> IssueCallback
Functor type of the callback on some issue (error or warning).
Defines the logger used by the top-level component of kea-dhcp-ddns.
Forward declarations for definitions of libdns++.
ZoneCheckerCallbacks(const IssueCallback &error_callback, const IssueCallback &warn_callback)
Constructor.
void error(const std::string &reason) const
Call the callback for a critical error.
void warn(const std::string &reason) const
Call the callback for a non critical issue.