NOX: IPv4over4 - Separated protocol and widget as per new framework
This commit is contained in:
parent
d818b90a8f
commit
710b295d74
35
common/ip4over4config.h
Normal file
35
common/ip4over4config.h
Normal file
@ -0,0 +1,35 @@
|
||||
/*
|
||||
Copyright (C) 2010 Srivats P.
|
||||
|
||||
This file is part of "Ostinato"
|
||||
|
||||
This is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
|
||||
#ifndef _IP_4_OVER_4_CONFIG_H
|
||||
#define _IP_4_OVER_4_CONFIG_H
|
||||
|
||||
#include "comboprotocolconfig.h"
|
||||
#include "ip4config.h"
|
||||
#include "ip4.h"
|
||||
|
||||
#include "protocol.pb.h"
|
||||
|
||||
typedef ComboProtocolConfigForm <
|
||||
OstProto::Protocol::kIp4over4FieldNumber,
|
||||
Ip4ConfigForm, Ip4ConfigForm,
|
||||
Ip4Protocol, Ip4Protocol
|
||||
> Ip4over4ConfigForm;
|
||||
|
||||
#endif
|
@ -58,14 +58,14 @@ HEADERS += \
|
||||
dot2snap.h \
|
||||
arp.h \
|
||||
ip4.h \
|
||||
ip6.h
|
||||
ip6.h \
|
||||
ip4over4.h
|
||||
|
||||
HEADERS1 += \
|
||||
ipv4addressdelegate.h \
|
||||
ipv6addressdelegate.h \
|
||||
ip6over4.h \
|
||||
ip4over6.h \
|
||||
ip4over4.h \
|
||||
ip6over6.h \
|
||||
icmp.h \
|
||||
gmp.h \
|
||||
|
@ -60,7 +60,8 @@ HEADERS += \
|
||||
dot2snapconfig.h \
|
||||
arpconfig.h \
|
||||
ip4config.h \
|
||||
ip6config.h
|
||||
ip6config.h \
|
||||
ip4over4config.h
|
||||
|
||||
SOURCES += \
|
||||
ostprotolib.cpp \
|
||||
|
@ -24,7 +24,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>
|
||||
#if 0
|
||||
#include "ip6over4.h"
|
||||
#include "ip4over6.h"
|
||||
#include "ip4over4.h"
|
||||
#include "ip6over6.h"
|
||||
#include "icmp.h"
|
||||
#include "igmp.h"
|
||||
@ -50,6 +49,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>
|
||||
#include "arp.h"
|
||||
#include "ip4.h"
|
||||
#include "ip6.h"
|
||||
#include "ip4over4.h"
|
||||
#endif
|
||||
|
||||
ProtocolManager *OstProtocolManager;
|
||||
@ -64,8 +64,6 @@ ProtocolManager::ProtocolManager()
|
||||
(void*) Ip6over4Protocol::createInstance);
|
||||
registerProtocol(OstProto::Protocol::kIp4over6FieldNumber,
|
||||
(void*) Ip4over6Protocol::createInstance);
|
||||
registerProtocol(OstProto::Protocol::kIp4over4FieldNumber,
|
||||
(void*) Ip4over4Protocol::createInstance);
|
||||
registerProtocol(OstProto::Protocol::kIp6over6FieldNumber,
|
||||
(void*) Ip6over6Protocol::createInstance);
|
||||
|
||||
@ -121,6 +119,9 @@ ProtocolManager::ProtocolManager()
|
||||
(void*) Ip4Protocol::createInstance);
|
||||
registerProtocol(OstProto::Protocol::kIp6FieldNumber,
|
||||
(void*) Ip6Protocol::createInstance);
|
||||
|
||||
registerProtocol(OstProto::Protocol::kIp4over4FieldNumber,
|
||||
(void*) Ip4over4Protocol::createInstance);
|
||||
#endif
|
||||
populateNeighbourProtocols();
|
||||
}
|
||||
|
@ -33,6 +33,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>
|
||||
#include "arpconfig.h"
|
||||
#include "ip4config.h"
|
||||
#include "ip6config.h"
|
||||
#include "ip4over4config.h"
|
||||
|
||||
ProtocolWidgetFactory *OstProtocolWidgetFactory;
|
||||
QMap<int, void*> ProtocolWidgetFactory::configWidgetFactory;
|
||||
@ -88,6 +89,10 @@ ProtocolWidgetFactory::ProtocolWidgetFactory()
|
||||
OstProtocolWidgetFactory->registerProtocolConfigWidget(
|
||||
OstProto::Protocol::kIp6FieldNumber,
|
||||
(void*) Ip6ConfigForm::createInstance);
|
||||
|
||||
OstProtocolWidgetFactory->registerProtocolConfigWidget(
|
||||
OstProto::Protocol::kIp4over4FieldNumber,
|
||||
(void*) Ip4over4ConfigForm::createInstance);
|
||||
}
|
||||
|
||||
ProtocolWidgetFactory::~ProtocolWidgetFactory()
|
||||
|
Loading…
Reference in New Issue
Block a user