Kea 2.7.6
stamped_element.h
Go to the documentation of this file.
1// Copyright (C) 2018-2019 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 STAMPED_ELEMENT_H
8#define STAMPED_ELEMENT_H
9
11#include <cc/server_tag.h>
12#include <set>
13
14namespace isc {
15namespace data {
16
35public:
36
41
46 void setServerTag(const std::string& server_tag) {
47 server_tags_.insert(ServerTag(server_tag));
48 }
49
56 void delServerTag(const std::string& server_tag);
57
61 std::set<ServerTag> getServerTags() const {
62 return (server_tags_);
63 }
64
69 bool hasServerTag(const ServerTag& server_tag) const;
70
74 bool hasAllServerTag() const;
75
81
82private:
83
85 std::set<ServerTag> server_tags_;
86};
87
88} // end of namespace isc::data
89} // end of namespace isc
90
91#endif
This class represents configuration element which is associated with database identifier and the modi...
Represents a server tag.
Definition server_tag.h:25
This class represents configuration element which is associated with database identifier,...
void delServerTag(const std::string &server_tag)
Deletes server tag.
isc::data::ElementPtr getMetadata() const
Returns an object representing metadata to be returned with objects from the configuration backend.
std::set< ServerTag > getServerTags() const
Returns server tags.
bool hasAllServerTag() const
Checks if the element has 'all' server tag.
bool hasServerTag(const ServerTag &server_tag) const
Checks if the element has the given server tag.
void setServerTag(const std::string &server_tag)
Adds new server tag.
boost::shared_ptr< Element > ElementPtr
Definition data.h:28
Defines the logger used by the top-level component of kea-lfc.