NetSim Source Code Help
Loading...
Searching...
No Matches
Routing.h
Go to the documentation of this file.
1/************************************************************************************
2* Copyright (C) 2020 *
3* TETCOS, Bangalore. India *
4* *
5* Tetcos owns the intellectual property rights in the Product and its content. *
6* The copying, redistribution, reselling or publication of any or all of the *
7* Product or its content without express prior written consent of Tetcos is *
8* prohibited. Ownership and / or any other right relating to the software and all *
9* intellectual property rights therein shall remain at all times with Tetcos. *
10* *
11* Author: Thangarasu *
12* *
13* ---------------------------------------------------------------------------------*/
14#ifndef _ROUTING_H_
15#define _ROUTING_H_
16#ifdef __cplusplus
17extern "C" {
18#endif
19#include "RIP.h"
21int (*fnRouter[10])();
22/** Structure for NetSim Router */
24{
26 {
27 struct stru_RIP struRIP; //RIP
34};
35/** Structure for router buffer */
37{
39};
40/** Structure to store Routing Tables*/
42{
44};
45
46_declspec(dllexport)int fn_NetSim_UpdateEntryinRoutingTable(struct stru_NetSim_Network *NETWORK,NetSim_EVENTDETAILS *pstruEventDetails,NETSIM_ID nDeviceId,NETSIM_ID nInterfaceId,unsigned int bgpRemoteAS,NETSIM_IPAddress szDestinationIP,NETSIM_IPAddress szNexthop,NETSIM_IPAddress szSubnetmask,unsigned int prefix_len,int nCost,int nFlag);
47_declspec(dllexport)int UpdateInterfaceList();
50
51#ifdef __cplusplus
52}
53#endif
54#endif
unsigned int NETSIM_ID
Definition: Animation.h:45
#define _declspec(dllexport)
This function is used to trigger the update.
Definition: Linux.h:41
APPLICATION_LAYER_PROTOCOL fnCheckRoutingProtocol(NETSIM_ID deviceId)
Definition: Routing.c:84
int fn_NetSim_UpdateEntryinRoutingTable(struct stru_NetSim_Network *NETWORK, NetSim_EVENTDETAILS *pstruEventDetails, NETSIM_ID nDeviceId, NETSIM_ID nInterfaceId, unsigned int bgpRemoteAS, NETSIM_IPAddress szDestinationIP, NETSIM_IPAddress szNexthop, NETSIM_IPAddress szSubnetmask, unsigned int prefix_len, int nCost, int nFlag)
Definition: Routing.c:30
int(* fnRouter[10])()
Definition: Routing.h:21
int UpdateInterfaceList()
Definition: Routing.c:45
int fnCheckRoutingPacket()
Definition: Routing.c:77
EXPORTED struct stru_NetSim_Network * NETWORK
Definition: Stack.h:742
EXPORTED struct stru_NetSim_EventDetails * pstruEventDetails
Definition: Stack.h:837
enum enum_AppProtocol APPLICATION_LAYER_PROTOCOL
Definition: main.h:131
APPLICATION_LAYER_PROTOCOL AppIntRoutingProtocol
Definition: Routing.h:30
ROUTING_TABLES * pstruRoutingTables
Definition: Routing.h:29
APPLICATION_LAYER_PROTOCOL AppExtRoutingProtocol
Definition: Routing.h:31
APPLICATION_LAYER_PROTOCOL * RoutingProtocol
Definition: Routing.h:32
ptrSOCKETINTERFACE sock
Definition: Routing.h:33
union stru_NetSim_Router::uni_Interior_Routing uniInteriorRouting
Definition: RIP.h:141
RIP_ROUTING_DATABASE * pstruRIP_RoutingTable
Definition: Routing.h:43
NetSim_BUFFER * pstruBuffer
Definition: Routing.h:38
Routing database structure Reference : RFC 2453, November 1998, Page 8.
Definition: RIP.h:73