Kea  2.3.5-git
shared_network_parser.h
Go to the documentation of this file.
1 // Copyright (C) 2017-2021 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 SHARED_SUBNET_PARSER_H
8 #define SHARED_SUBNET_PARSER_H
9 
10 #include <cc/data.h>
11 #include <cc/simple_parser.h>
12 #include <dhcpsrv/cfg_subnets4.h>
13 #include <dhcpsrv/cfg_subnets6.h>
14 #include <dhcpsrv/shared_network.h>
18 #include <boost/shared_ptr.hpp>
19 
20 namespace isc {
21 namespace dhcp {
22 
25 public:
30  SharedNetwork4Parser(bool check_iface = true);
31 
34  }
35 
44  parse(const data::ConstElementPtr& shared_network_data);
45 
46 protected:
47 
55  virtual boost::shared_ptr<OptionDataListParser> createOptionDataListParser() const;
56 
64  virtual boost::shared_ptr<Subnets4ListConfigParser> createSubnetsListParser() const;
65 
68 };
69 
72 public:
77  SharedNetwork6Parser(bool check_iface = true);
78 
81  }
82 
91  parse(const data::ConstElementPtr& shared_network_data);
92 
93 protected:
94 
102  virtual boost::shared_ptr<OptionDataListParser> createOptionDataListParser() const;
103 
111  virtual boost::shared_ptr<Subnets6ListConfigParser> createSubnetsListParser() const;
112 
115 };
116 
117 } // enf of namespace isc::dhcp
118 } // end of namespace isc
119 
120 #endif // SHARED_SUBNET_PARSER_H
virtual ~SharedNetwork6Parser()
Virtual destructor.
bool check_iface_
Check if the specified interface exists in the system.
Common configuration parser for shared networks and subnets.
virtual boost::shared_ptr< OptionDataListParser > createOptionDataListParser() const
Returns an instance of the OptionDataListParser to be used in parsing the option-data structure...
bool check_iface_
Check if the specified interface exists in the system.
Implements parser for IPv4 shared networks.
boost::shared_ptr< const Element > ConstElementPtr
Definition: data.h:27
boost::shared_ptr< SharedNetwork6 > SharedNetwork6Ptr
Pointer to SharedNetwork6 object.
virtual boost::shared_ptr< Subnets4ListConfigParser > createSubnetsListParser() const
Returns an instance of the Subnets4ListConfigParser to be used for parsing the subnets within the sha...
boost::shared_ptr< SharedNetwork4 > SharedNetwork4Ptr
Pointer to SharedNetwork4 object.
Defines the logger used by the top-level component of kea-lfc.
virtual ~SharedNetwork4Parser()
Virtual destructor.
Implements parser for IPv6 shared networks.
SharedNetwork4Ptr parse(const data::ConstElementPtr &shared_network_data)
Parses shared configuration information for IPv4 shared network.
SharedNetwork4Parser(bool check_iface=true)
Constructor.