OpenSDN source code
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
VrouterControlInterface Class Referenceabstract

#include <vrouter_interface.h>

Inheritance diagram for VrouterControlInterface:
Collaboration diagram for VrouterControlInterface:

Public Member Functions

 VrouterControlInterface ()
 
virtual ~VrouterControlInterface ()
 
virtual void InitControlInterface ()
 
virtual uint32_t EncapsulationLength () const
 
int DecodeAgentHdr (AgentHdr *hdr, uint8_t *buff, uint32_t len)
 
bool Process (const PacketBufferPtr &pkt)
 
int EncodeAgentHdr (uint8_t *buff, const AgentHdr &hdr)
 
virtual int Send (const AgentHdr &hdr, const PacketBufferPtr &pkt)
 
virtual int Send (uint8_t *buff, uint16_t buf_len, const PacketBufferPtr &pkt)=0
 
- Public Member Functions inherited from ControlInterface
 ControlInterface ()
 
virtual ~ControlInterface ()
 
void Init (PktHandler *pkt_handler)
 
void Shutdown ()
 
void IoShutdown ()
 
virtual void ShutdownControlInterface ()=0
 
virtual void IoShutdownControlInterface ()=0
 
virtual const std::string & Name () const =0
 
bool Process (const AgentHdr &hdr, const PacketBufferPtr &pkt)
 
PktHandlerpkt_handler () const
 

Static Public Attributes

static const uint32_t kAgentHdrLen
 
- Static Public Attributes inherited from ControlInterface
static const uint32_t kMaxPacketSize = 9060
 

Private Member Functions

AgentHdr::PktCommand VrCmdToAgentCmd (uint16_t vr_cmd)
 
AgentHdr::PktCommandParams VrCmdParamtoAgentCmdParam (uint16_t param)
 
uint16_t AgentCmdToVrCmd (AgentHdr::PktCommand agent_cmd)
 
 DISALLOW_COPY_AND_ASSIGN (VrouterControlInterface)
 

Private Attributes

std::vector< AgentHdr::PktCommandvr_cmd_list_
 
std::vector
< AgentHdr::PktCommandParams
vr_cmd_params_list_
 
std::vector< uint16_t > agent_cmd_list_
 

Detailed Description

Definition at line 16 of file vrouter_interface.h.

Constructor & Destructor Documentation

VrouterControlInterface::VrouterControlInterface ( )
inline

Definition at line 21 of file vrouter_interface.h.

virtual VrouterControlInterface::~VrouterControlInterface ( )
inlinevirtual

Definition at line 22 of file vrouter_interface.h.

Member Function Documentation

uint16_t VrouterControlInterface::AgentCmdToVrCmd ( AgentHdr::PktCommand  agent_cmd)
inlineprivate

Definition at line 173 of file vrouter_interface.h.

int VrouterControlInterface::DecodeAgentHdr ( AgentHdr hdr,
uint8_t *  buff,
uint32_t  len 
)
inline

Definition at line 74 of file vrouter_interface.h.

Here is the call graph for this function:

VrouterControlInterface::DISALLOW_COPY_AND_ASSIGN ( VrouterControlInterface  )
private
virtual uint32_t VrouterControlInterface::EncapsulationLength ( ) const
inlinevirtual

Implements ControlInterface.

Definition at line 70 of file vrouter_interface.h.

int VrouterControlInterface::EncodeAgentHdr ( uint8_t *  buff,
const AgentHdr hdr 
)
inline

Definition at line 119 of file vrouter_interface.h.

virtual void VrouterControlInterface::InitControlInterface ( )
inlinevirtual

Implements ControlInterface.

Reimplemented in Pkt0Socket, Pkt0RawInterface, and Pkt0Interface.

Definition at line 28 of file vrouter_interface.h.

bool VrouterControlInterface::Process ( const PacketBufferPtr pkt)
inline

Definition at line 106 of file vrouter_interface.h.

Here is the call graph for this function:

virtual int VrouterControlInterface::Send ( const AgentHdr hdr,
const PacketBufferPtr pkt 
)
inlinevirtual

Implements ControlInterface.

Definition at line 140 of file vrouter_interface.h.

Here is the call graph for this function:

virtual int VrouterControlInterface::Send ( uint8_t *  buff,
uint16_t  buf_len,
const PacketBufferPtr pkt 
)
pure virtual

Implemented in Pkt0Socket, and Pkt0Interface.

AgentHdr::PktCommandParams VrouterControlInterface::VrCmdParamtoAgentCmdParam ( uint16_t  param)
inlineprivate

Definition at line 164 of file vrouter_interface.h.

AgentHdr::PktCommand VrouterControlInterface::VrCmdToAgentCmd ( uint16_t  vr_cmd)
inlineprivate

Definition at line 155 of file vrouter_interface.h.

Member Data Documentation

std::vector<uint16_t> VrouterControlInterface::agent_cmd_list_
private

Definition at line 180 of file vrouter_interface.h.

const uint32_t VrouterControlInterface::kAgentHdrLen
static
Initial value:
=
(sizeof(ether_header) + sizeof(struct agent_hdr))

Definition at line 18 of file vrouter_interface.h.

std::vector<AgentHdr::PktCommand> VrouterControlInterface::vr_cmd_list_
private

Definition at line 178 of file vrouter_interface.h.

std::vector<AgentHdr::PktCommandParams> VrouterControlInterface::vr_cmd_params_list_
private

Definition at line 179 of file vrouter_interface.h.


The documentation for this class was generated from the following file: