NetSim Source Code Help
Loading...
Searching...
No Matches
PIM_Msg.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_pim_hdr
 
struct  stru_pim_encoded_unicast_addr
 
struct  stru_pim_encoded_group_addr
 
struct  stru_pim_encoded_source_addr
 
struct  stru_pim_hello_option
 
struct  stru_option_holdtime
 
struct  stru_option_lan_prune_delay
 
struct  stru_option_dr_priority
 
struct  stru_option_gen_id
 
struct  stru_option_addrlist
 
struct  stru_pim_Hello
 
struct  stru_pim_register_msg
 
struct  stru_pim_register_stop_msg
 
struct  stru_msg_groups
 
struct  stru_pim_join_prune_msg
 

Macros

#define _NETSIM_PIM_MSG_H_
 
#define PIM_VER   2
 
#define PIM_HDR_LEN   4
 
#define ENCODED_UNICAST_ADDR_LEN   6
 
#define ENCODED_GROUP_ADDR_LEN   8
 
#define ENCODED_SOURCE_ADDR_LEN   8
 
#define PIM_HELLO_OPTION_LEN   4
 
#define PIM_OPTION_HOLDTIME_LEN   2
 
#define PIM_OPTION_HOLDTIME_TYPE   1
 
#define PIM_OPTION_LANPRUNEDELAY_LEN   4
 
#define PIM_OPTION_LANPRUNEDELAY_TYPE   2
 
#define PIM_OPTION_DRPRIORITY_LEN   4
 
#define PIM_OPTION_DRPRIORITY_TYPE   19
 
#define PIM_OPTION_GENERATIONID_LEN   4
 
#define PIM_OPTION_GENERATIONID_TYPE   20
 
#define PIM_OPTION_ADDRLIST_LEN   0
 
#define PIM_OPTION_ADDRLIST_TYPE   24
 
#define PIM_HELLO_LEN   0
 
#define PIM_JP_MSG_LEN   (ENCODED_UNICAST_ADDR_LEN+4)
 

Typedefs

typedef enum enum_pim_msg_type PIMMSG
 
typedef struct stru_pim_hdr PIM_HDR
 
typedef struct stru_pim_hdrptrPIM_HDR
 
typedef struct stru_pim_encoded_unicast_addr ENCODED_UNICAST_ADDR
 
typedef struct stru_pim_encoded_unicast_addrptrENCODED_UNICAST_ADDR
 
typedef struct stru_pim_encoded_group_addr ENCODED_GROUP_ADDR
 
typedef struct stru_pim_encoded_group_addrptrENCODED_GROUP_ADDR
 
typedef struct stru_pim_encoded_source_addr ENCODED_SOURCE_ADDR
 
typedef struct stru_pim_encoded_source_addrptrENCODED_SOURCE_ADDR
 
typedef struct stru_pim_hello_option PIM_HELLO_OPTION
 
typedef struct stru_pim_hello_optionptrPIM_HELLO_OPTION
 
typedef struct stru_option_holdtime OPTION_HOLDTIME
 
typedef struct stru_option_holdtimeptrOPTION_HOLDTIME
 
typedef struct stru_option_lan_prune_delay OPTION_LANPRUNEDELAY
 
typedef struct stru_option_lan_prune_delayptrOPTION_LANPRUNEDELAY
 
typedef struct stru_option_dr_priority OPTION_DRPRIORITY
 
typedef struct stru_option_dr_priorityptrOPTION_DRPRIORITY
 
typedef struct stru_option_gen_id OPTION_GENERATIONID
 
typedef struct stru_option_gen_idptrOPTION_GENERATIONID
 
typedef struct stru_option_addrlist OPTION_ADDRLIST
 
typedef struct stru_option_addrlistptrOPTION_ADDRLIST
 
typedef struct stru_pim_Hello PIM_HELLO
 
typedef struct stru_pim_HelloptrPIM_HELLO
 
typedef struct stru_pim_register_msg PIM_REGISTERMSG
 
typedef struct stru_pim_register_msgptrPIM_REGISTERMSG
 
typedef struct stru_pim_register_stop_msg PIM_REGISTERSTOPMSG
 
typedef struct stru_pim_register_stop_msgptrPIM_REGISTERSTOPMSG
 
typedef struct stru_msg_groups PIM_JOINMSG_GROUP
 
typedef struct stru_msg_groupsptrPIM_JOINMSG_GROUP
 
typedef struct stru_pim_join_prune_msg PIM_JOINPRUNE_MSG
 
typedef struct stru_pim_join_prune_msgptrPIM_JOINPRUNE_MSG
 

Enumerations

enum  enum_pim_msg_type {
  PIMMSG_Hello , PIMMSG_Register , PIMMSG_RegisterStop , PIMMSG_JoinPrune ,
  PIMMSG_Bootstrap , PIMMSG_Assert , PIMMSG_Graft , PIMMSG_GraftAck ,
  PIMMSG_CandidateRPAdvertisement
}
 

Functions

void * get_PIM_MSG (NetSim_PACKET *packet)
 
void set_PIM_MSG (NetSim_PACKET *packet, void *msg)
 
void set_pim_hdr (ptrPIM_HDR hdr, PIMMSG type)
 
NetSim_PACKETcreate_pim_packet (PIMMSG type, void *opt, double time, NETSIM_ID source, NETSIM_IPAddress sourceAddrss, UINT destCount, NETSIM_ID *destList, NETSIM_IPAddress group, UINT ttl)
 
void send_pim_msg (NETSIM_ID d, double time, NetSim_PACKET *packet)
 
ptrENCODED_UNICAST_ADDR encode_unicast_addr (NETSIM_IPAddress ip)
 
ptrENCODED_SOURCE_ADDR encode_source_addr (NETSIM_IPAddress ip, NETSIM_IPAddress subnet)
 
ptrENCODED_GROUP_ADDR encode_group_addr (NETSIM_IPAddress ip)
 

Macro Definition Documentation

◆ _NETSIM_PIM_MSG_H_

#define _NETSIM_PIM_MSG_H_

Definition at line 16 of file PIM_Msg.h.

◆ ENCODED_GROUP_ADDR_LEN

#define ENCODED_GROUP_ADDR_LEN   8

Definition at line 113 of file PIM_Msg.h.

◆ ENCODED_SOURCE_ADDR_LEN

#define ENCODED_SOURCE_ADDR_LEN   8

Definition at line 139 of file PIM_Msg.h.

◆ ENCODED_UNICAST_ADDR_LEN

#define ENCODED_UNICAST_ADDR_LEN   6

Definition at line 88 of file PIM_Msg.h.

◆ PIM_HDR_LEN

#define PIM_HDR_LEN   4

Definition at line 69 of file PIM_Msg.h.

◆ PIM_HELLO_LEN

#define PIM_HELLO_LEN   0

Definition at line 278 of file PIM_Msg.h.

◆ PIM_HELLO_OPTION_LEN

#define PIM_HELLO_OPTION_LEN   4

Definition at line 147 of file PIM_Msg.h.

◆ PIM_JP_MSG_LEN

#define PIM_JP_MSG_LEN   (ENCODED_UNICAST_ADDR_LEN+4)

Definition at line 409 of file PIM_Msg.h.

◆ PIM_OPTION_ADDRLIST_LEN

#define PIM_OPTION_ADDRLIST_LEN   0

Definition at line 243 of file PIM_Msg.h.

◆ PIM_OPTION_ADDRLIST_TYPE

#define PIM_OPTION_ADDRLIST_TYPE   24

Definition at line 244 of file PIM_Msg.h.

◆ PIM_OPTION_DRPRIORITY_LEN

#define PIM_OPTION_DRPRIORITY_LEN   4

Definition at line 202 of file PIM_Msg.h.

◆ PIM_OPTION_DRPRIORITY_TYPE

#define PIM_OPTION_DRPRIORITY_TYPE   19

Definition at line 203 of file PIM_Msg.h.

◆ PIM_OPTION_GENERATIONID_LEN

#define PIM_OPTION_GENERATIONID_LEN   4

Definition at line 220 of file PIM_Msg.h.

◆ PIM_OPTION_GENERATIONID_TYPE

#define PIM_OPTION_GENERATIONID_TYPE   20

Definition at line 221 of file PIM_Msg.h.

◆ PIM_OPTION_HOLDTIME_LEN

#define PIM_OPTION_HOLDTIME_LEN   2

Definition at line 164 of file PIM_Msg.h.

◆ PIM_OPTION_HOLDTIME_TYPE

#define PIM_OPTION_HOLDTIME_TYPE   1

Definition at line 165 of file PIM_Msg.h.

◆ PIM_OPTION_LANPRUNEDELAY_LEN

#define PIM_OPTION_LANPRUNEDELAY_LEN   4

Definition at line 184 of file PIM_Msg.h.

◆ PIM_OPTION_LANPRUNEDELAY_TYPE

#define PIM_OPTION_LANPRUNEDELAY_TYPE   2

Definition at line 185 of file PIM_Msg.h.

◆ PIM_VER

#define PIM_VER   2

Definition at line 68 of file PIM_Msg.h.

Typedef Documentation

◆ ENCODED_GROUP_ADDR

◆ ENCODED_SOURCE_ADDR

◆ ENCODED_UNICAST_ADDR

◆ OPTION_ADDRLIST

◆ OPTION_DRPRIORITY

◆ OPTION_GENERATIONID

◆ OPTION_HOLDTIME

◆ OPTION_LANPRUNEDELAY

◆ PIM_HDR

typedef struct stru_pim_hdr PIM_HDR

◆ PIM_HELLO

typedef struct stru_pim_Hello PIM_HELLO

◆ PIM_HELLO_OPTION

◆ PIM_JOINMSG_GROUP

◆ PIM_JOINPRUNE_MSG

◆ PIM_REGISTERMSG

◆ PIM_REGISTERSTOPMSG

◆ PIMMSG

typedef enum enum_pim_msg_type PIMMSG

◆ ptrENCODED_GROUP_ADDR

◆ ptrENCODED_SOURCE_ADDR

◆ ptrENCODED_UNICAST_ADDR

◆ ptrOPTION_ADDRLIST

◆ ptrOPTION_DRPRIORITY

◆ ptrOPTION_GENERATIONID

◆ ptrOPTION_HOLDTIME

◆ ptrOPTION_LANPRUNEDELAY

◆ ptrPIM_HDR

typedef struct stru_pim_hdr * ptrPIM_HDR

◆ ptrPIM_HELLO

typedef struct stru_pim_Hello * ptrPIM_HELLO

◆ ptrPIM_HELLO_OPTION

◆ ptrPIM_JOINMSG_GROUP

◆ ptrPIM_JOINPRUNE_MSG

◆ ptrPIM_REGISTERMSG

◆ ptrPIM_REGISTERSTOPMSG

Enumeration Type Documentation

◆ enum_pim_msg_type

Enumerator
PIMMSG_Hello 
PIMMSG_Register 
PIMMSG_RegisterStop 
PIMMSG_JoinPrune 
PIMMSG_Bootstrap 
PIMMSG_Assert 
PIMMSG_Graft 
PIMMSG_GraftAck 
PIMMSG_CandidateRPAdvertisement 

Definition at line 39 of file PIM_Msg.h.

Function Documentation

◆ create_pim_packet()

NetSim_PACKET * create_pim_packet ( PIMMSG  type,
void *  opt,
double  time,
NETSIM_ID  source,
NETSIM_IPAddress  sourceAddrss,
UINT  destCount,
NETSIM_ID destList,
NETSIM_IPAddress  group,
UINT  ttl 
)

Definition at line 91 of file PIM_Msg.c.

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

◆ encode_group_addr()

ptrENCODED_GROUP_ADDR encode_group_addr ( NETSIM_IPAddress  ip)

Definition at line 182 of file PIM_Msg.c.

Here is the caller graph for this function:

◆ encode_source_addr()

ptrENCODED_SOURCE_ADDR encode_source_addr ( NETSIM_IPAddress  ip,
NETSIM_IPAddress  subnet 
)

Definition at line 172 of file PIM_Msg.c.

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

◆ encode_unicast_addr()

ptrENCODED_UNICAST_ADDR encode_unicast_addr ( NETSIM_IPAddress  ip)

Definition at line 151 of file PIM_Msg.c.

Here is the caller graph for this function:

◆ get_PIM_MSG()

void * get_PIM_MSG ( NetSim_PACKET packet)

Definition at line 21 of file PIM_Msg.c.

Here is the caller graph for this function:

◆ send_pim_msg()

void send_pim_msg ( NETSIM_ID  d,
double  time,
NetSim_PACKET packet 
)

Definition at line 125 of file PIM_Msg.c.

Here is the caller graph for this function:

◆ set_pim_hdr()

void set_pim_hdr ( ptrPIM_HDR  hdr,
PIMMSG  type 
)

Definition at line 145 of file PIM_Msg.c.

Here is the caller graph for this function:

◆ set_PIM_MSG()

void set_PIM_MSG ( NetSim_PACKET packet,
void *  msg 
)

Definition at line 26 of file PIM_Msg.c.

Here is the caller graph for this function: