Kea 1.5.0
user_context.h
Go to the documentation of this file.
1// Copyright (C) 2017-2018 Internet Systems Consortium, Inc. ("ISC")
2//
3// This Source Code Form is subject to the terms of the Mozilla Public
4// License, v. 2.0. If a copy of the MPL was not distributed with this
5// file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
7#ifndef USER_CONTEXT_H
8#define USER_CONTEXT_H
9
10#include <cc/data.h>
11#include <boost/shared_ptr.hpp>
12
13namespace isc {
14namespace data {
15
25 return (user_context_);
26 }
27
31 user_context_ = ctx;
32 }
33
40 void contextToElement(data::ElementPtr map) const;
41
47
48protected:
49
52};
53
54} // end of isc::dhcp namespace
55} // end of isc namespace
56
57
58#endif // USER_CONTEXT_H
boost::shared_ptr< const Element > ConstElementPtr
Definition: data.h:23
boost::shared_ptr< Element > ElementPtr
Definition: data.h:22
Defines the logger used by the top-level component of kea-dhcp-ddns.
Base class for user context.
Definition: user_context.h:22
data::ConstElementPtr user_context_
Pointer to the user context (may be NULL)
Definition: user_context.h:51
data::ConstElementPtr getContext() const
Returns const pointer to the user context.
Definition: user_context.h:24
void contextToElement(data::ElementPtr map) const
Merge unparse a user_context object.
Definition: user_context.cc:15
static data::ElementPtr toElement(data::ConstElementPtr map)
Copy extracting comments an Element map.
Definition: user_context.cc:34
void setContext(const data::ConstElementPtr &ctx)
Sets user context.
Definition: user_context.h:30