2016-09-12 12:55:12 +02:00
|
|
|
/*
|
|
|
|
* \brief IP routing entry
|
|
|
|
* \author Martin Stein
|
|
|
|
* \date 2016-08-19
|
|
|
|
*/
|
|
|
|
|
|
|
|
/*
|
2017-02-20 13:23:52 +01:00
|
|
|
* Copyright (C) 2016-2017 Genode Labs GmbH
|
2016-09-12 12:55:12 +02:00
|
|
|
*
|
|
|
|
* This file is part of the Genode OS framework, which is distributed
|
2017-02-20 13:23:52 +01:00
|
|
|
* under the terms of the GNU Affero General Public License version 3.
|
2016-09-12 12:55:12 +02:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _IP_RULE_H_
|
|
|
|
#define _IP_RULE_H_
|
|
|
|
|
|
|
|
/* local includes */
|
2019-10-03 20:30:26 +02:00
|
|
|
#include "direct_rule.h"
|
2016-09-12 12:55:12 +02:00
|
|
|
|
|
|
|
namespace Net {
|
|
|
|
|
2018-05-27 01:10:52 +02:00
|
|
|
class Domain;
|
|
|
|
class Domain_tree;
|
|
|
|
|
2016-09-12 12:55:12 +02:00
|
|
|
class Ip_rule;
|
|
|
|
struct Ip_rule_list : Direct_rule_list<Ip_rule> { };
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2018-05-27 01:10:52 +02:00
|
|
|
class Net::Ip_rule : public Direct_rule<Ip_rule>
|
2016-09-12 12:55:12 +02:00
|
|
|
{
|
2018-05-27 01:10:52 +02:00
|
|
|
private:
|
|
|
|
|
|
|
|
Domain &_domain;
|
|
|
|
|
|
|
|
static Domain &_find_domain(Domain_tree &domains,
|
|
|
|
Genode::Xml_node const node);
|
|
|
|
|
2016-09-12 12:55:12 +02:00
|
|
|
public:
|
|
|
|
|
2016-12-06 14:39:17 +01:00
|
|
|
Ip_rule(Domain_tree &domains, Genode::Xml_node const node);
|
2018-05-27 01:10:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
/***************
|
|
|
|
** Accessors **
|
|
|
|
***************/
|
|
|
|
|
|
|
|
Domain &domain() const { return _domain; }
|
2016-09-12 12:55:12 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif /* _IP_RULE_H_ */
|