// Parsing the lease may throw and it means that the lease
// information is malformed.
Parameters p = getParameters(true, lease_params);
- auto lease = getIPv6AddressForDelete(p);
+ auto lease = getIPv6LeaseForDelete(p);
parsed_deleted_list.push_back(std::make_pair(p, lease));
}
}
ConstElementPtr ctx = lease->getContext();
if (ctx) {
bind_[10].buffer_type = MYSQL_TYPE_STRING;
- string ctx_txt = ctx->str();
+ std::string ctx_txt = ctx->str();
strncpy(user_context_, ctx_txt.c_str(), USER_CONTEXT_MAX_LEN - 1);
bind_[10].buffer = user_context_;
bind_[10].buffer_length = ctx_txt.length();
ConstElementPtr ctx = lease->getContext();
if (ctx) {
bind_[16].buffer_type = MYSQL_TYPE_STRING;
- string ctx_txt = ctx->str();
+ std::string ctx_txt = ctx->str();
strncpy(user_context_, ctx_txt.c_str(), USER_CONTEXT_MAX_LEN - 1);
bind_[16].buffer = user_context_;
bind_[16].buffer_length = ctx_txt.length();
}
Lease4Collection
-MySqlLeaseMgr::getLeases4(const string& hostname) const {
+MySqlLeaseMgr::getLeases4(const std::string& hostname) const {
LOG_DEBUG(dhcpsrv_logger, DHCPSRV_DBG_TRACE_DETAIL, DHCPSRV_MYSQL_GET_HOSTNAME4)
.arg(hostname);
}
Lease6Collection
-MySqlLeaseMgr::getLeases6(const string& hostname) const {
+MySqlLeaseMgr::getLeases6(const std::string& hostname) const {
LOG_DEBUG(dhcpsrv_logger, DHCPSRV_DBG_TRACE_DETAIL, DHCPSRV_MYSQL_GET_HOSTNAME6)
.arg(hostname);
using namespace isc::dhcp;
using namespace isc::data;
using namespace isc::util;
+using namespace std;
namespace {
}
Lease4Collection
-PgSqlLeaseMgr::getLeases4(const string& hostname) const {
+PgSqlLeaseMgr::getLeases4(const std::string& hostname) const {
LOG_DEBUG(dhcpsrv_logger, DHCPSRV_DBG_TRACE_DETAIL, DHCPSRV_PGSQL_GET_HOSTNAME4)
.arg(hostname);
}
Lease6Collection
-PgSqlLeaseMgr::getLeases6(const string& hostname) const {
+PgSqlLeaseMgr::getLeases6(const std::string& hostname) const {
LOG_DEBUG(dhcpsrv_logger, DHCPSRV_DBG_TRACE_DETAIL, DHCPSRV_PGSQL_GET_HOSTNAME6)
.arg(hostname);
isc_throw(NotImplemented, "wipeLeases6 is not implemented for PostgreSQL backend");
}
-string
+std::string
PgSqlLeaseMgr::getName() const {
// Get a context
PgSqlLeaseContextAlloc get_context(*this);
PgSqlLeaseContextPtr ctx = get_context.ctx_;
- string name = "";
+ std::string name = "";
try {
name = ctx->conn_.getParameter("name");
} catch (...) {
return (name);
}
-string
+std::string
PgSqlLeaseMgr::getDescription() const {
- return (string("PostgreSQL Database"));
+ return (std::string("PostgreSQL Database"));
}
-pair<uint32_t, uint32_t>
+std::pair<uint32_t, uint32_t>
PgSqlLeaseMgr::getVersion() const {
LOG_DEBUG(dhcpsrv_logger, DHCPSRV_DBG_TRACE_DETAIL, DHCPSRV_PGSQL_GET_VERSION);