NetSim Source Code Help
Loading...
Searching...
No Matches
OpenFlow.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  stru_clientInfo
 
struct  stru_controllerInfo
 
struct  stru_HandleInfo
 
struct  stru_openflow
 
union  stru_openflow::sdn_info
 
struct  stru_openFlowMsg
 

Macros

#define _NETSIM_SDN_H_
 
#define OPENFLOW_SDN_CONTROLLER_DEFAULT   false
 
#define OPENFLOW_OPEN_FLOW_ENABLE_DEFAULT   false
 
#define OPENFLOW_SDN_CONTROLLER_DEVICE_DEFAULT   _strdup("unknown")
 
#define GET_OPENFLOW_VAR(d)   ((ptrOPENFLOW)(DEVICE_APPVAR(d,APP_PROTOCOL_OPENFLOW)))
 
#define SET_OPENFLOW_VAR(d, var)   (fn_NetSim_Stack_SetAppProtocolData(d,APP_PROTOCOL_OPENFLOW,var))
 
#define OFMSG_OVERHEAD   50
 
#define OFMSG_PORT   99
 

Typedefs

typedef struct stru_clientInfo SDNCLIENTINFO
 
typedef struct stru_clientInfoptrSDNCLIENTINFO
 
typedef struct stru_controllerInfo SDNCONTROLLERINFO
 
typedef struct stru_controllerInfoptrSDNCONTROLLERINFO
 
typedef struct stru_HandleInfo HANDLEINFO
 
typedef struct stru_HandleInfoptrHANDLEINFO
 
typedef struct stru_openflow OPENFLOW
 
typedef struct stru_openflowptrOPENFLOW
 
typedef enum enumOpenFlowMsgType OFMSGTYPE
 
typedef struct stru_openFlowMsg OPENFLOWMSG
 
typedef struct stru_openFlowMsgptrOPENFLOWMSG
 

Enumerations

enum  enumOpenFlowMsgType { OFMSGTYPE_COMMAND = APP_PROTOCOL_OPENFLOW * 100 + 1 , OFMSGTYPE_RESPONSE }
 

Functions

bool isOPENFLOWConfigured (NETSIM_ID d)
 
NETSIM_IPAddress openFlow_find_client_IP (NETSIM_ID d)
 
void handle_cli_input ()
 
char * openFlow_execute_command (void *handle, NETSIM_ID d, UINT id, int *len, bool *isMore)
 
void openFlow_saveHandle (NETSIM_ID d, UINT id, void *handle)
 
ptrHANDLEINFO openFlow_getHandle (NETSIM_ID d, UINT id)
 
bool isSDNController (NETSIM_ID d)
 
void openFlow_add_new_client (NETSIM_ID ct, NETSIM_ID ci, UINT16 port)
 
ptrSDNCLIENTINFO openFlow_find_clientInfo (NETSIM_ID ct, NETSIM_ID ci)
 
bool fn_NetSim_OPEN_FLOW_SendCommand (NETSIM_ID dest, void *handle, void *command, UINT len)
 
void openFlow_send_response (NETSIM_ID dev, UINT id, char *payload, int len, bool isMore)
 
void openFlow_print_response (NETSIM_ID d, UINT id, void *msg, int len, bool isMore)
 

Macro Definition Documentation

◆ _NETSIM_SDN_H_

#define _NETSIM_SDN_H_

Definition at line 17 of file OpenFlow.h.

◆ GET_OPENFLOW_VAR

#define GET_OPENFLOW_VAR (   d)    ((ptrOPENFLOW)(DEVICE_APPVAR(d,APP_PROTOCOL_OPENFLOW)))

Definition at line 72 of file OpenFlow.h.

◆ OFMSG_OVERHEAD

#define OFMSG_OVERHEAD   50

Definition at line 75 of file OpenFlow.h.

◆ OFMSG_PORT

#define OFMSG_PORT   99

Definition at line 76 of file OpenFlow.h.

◆ OPENFLOW_OPEN_FLOW_ENABLE_DEFAULT

#define OPENFLOW_OPEN_FLOW_ENABLE_DEFAULT   false

Definition at line 26 of file OpenFlow.h.

◆ OPENFLOW_SDN_CONTROLLER_DEFAULT

#define OPENFLOW_SDN_CONTROLLER_DEFAULT   false

Definition at line 25 of file OpenFlow.h.

◆ OPENFLOW_SDN_CONTROLLER_DEVICE_DEFAULT

#define OPENFLOW_SDN_CONTROLLER_DEVICE_DEFAULT   _strdup("unknown")

Definition at line 27 of file OpenFlow.h.

◆ SET_OPENFLOW_VAR

#define SET_OPENFLOW_VAR (   d,
  var 
)    (fn_NetSim_Stack_SetAppProtocolData(d,APP_PROTOCOL_OPENFLOW,var))

Definition at line 73 of file OpenFlow.h.

Typedef Documentation

◆ HANDLEINFO

typedef struct stru_HandleInfo HANDLEINFO

◆ OFMSGTYPE

◆ OPENFLOW

typedef struct stru_openflow OPENFLOW

◆ OPENFLOWMSG

typedef struct stru_openFlowMsg OPENFLOWMSG

◆ ptrHANDLEINFO

typedef struct stru_HandleInfo * ptrHANDLEINFO

◆ ptrOPENFLOW

typedef struct stru_openflow * ptrOPENFLOW

◆ ptrOPENFLOWMSG

typedef struct stru_openFlowMsg * ptrOPENFLOWMSG

◆ ptrSDNCLIENTINFO

◆ ptrSDNCONTROLLERINFO

◆ SDNCLIENTINFO

◆ SDNCONTROLLERINFO

Enumeration Type Documentation

◆ enumOpenFlowMsgType

Enumerator
OFMSGTYPE_COMMAND 
OFMSGTYPE_RESPONSE 

Definition at line 77 of file OpenFlow.h.

Function Documentation

◆ fn_NetSim_OPEN_FLOW_SendCommand()

bool fn_NetSim_OPEN_FLOW_SendCommand ( NETSIM_ID  dest,
void *  handle,
void *  command,
UINT  len 
)

Definition at line 110 of file OpenFlowMsg.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ handle_cli_input()

void handle_cli_input ( )

Definition at line 115 of file CLIInterface.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ isOPENFLOWConfigured()

bool isOPENFLOWConfigured ( NETSIM_ID  d)

Definition at line 194 of file OpenFlow.c.

Here is the caller graph for this function:

◆ isSDNController()

bool isSDNController ( NETSIM_ID  d)

Definition at line 17 of file SDNController.c.

Here is the caller graph for this function:

◆ openFlow_add_new_client()

void openFlow_add_new_client ( NETSIM_ID  ct,
NETSIM_ID  ci,
UINT16  port 
)

Definition at line 40 of file SDNController.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ openFlow_execute_command()

char * openFlow_execute_command ( void *  handle,
NETSIM_ID  d,
UINT  id,
int *  len,
bool *  isMore 
)

Definition at line 159 of file CLIInterface.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ openFlow_find_client_IP()

NETSIM_IPAddress openFlow_find_client_IP ( NETSIM_ID  d)

Definition at line 237 of file OpenFlow.c.

Here is the caller graph for this function:

◆ openFlow_find_clientInfo()

ptrSDNCLIENTINFO openFlow_find_clientInfo ( NETSIM_ID  ct,
NETSIM_ID  ci 
)

Definition at line 27 of file SDNController.c.

Here is the caller graph for this function:

◆ openFlow_getHandle()

ptrHANDLEINFO openFlow_getHandle ( NETSIM_ID  d,
UINT  id 
)

Definition at line 39 of file CLIInterface.c.

Here is the caller graph for this function:

◆ openFlow_print_response()

void openFlow_print_response ( NETSIM_ID  d,
UINT  id,
void *  msg,
int  len,
bool  isMore 
)

Definition at line 167 of file CLIInterface.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ openFlow_saveHandle()

void openFlow_saveHandle ( NETSIM_ID  d,
UINT  id,
void *  handle 
)

Definition at line 18 of file CLIInterface.c.

Here is the caller graph for this function:

◆ openFlow_send_response()

void openFlow_send_response ( NETSIM_ID  dev,
UINT  id,
char *  payload,
int  len,
bool  isMore 
)

Definition at line 145 of file OpenFlowMsg.c.

Here is the call graph for this function:
Here is the caller graph for this function: