class ResponsePacketAssembler

Class for RIP Response Packet Assemblers. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Types

Public Methods

Protected Methods

Protected Members


Detailed Description

Both RIPv2 and RIPng have some oddities in packing and this interface provides a consistent interface for that packing.

This class has specialized IPv4 and IPv6 implementations.

typedef A Addr

Addr

typedef IPNet<A> Net

Net

typedef PacketAssemblerSpecState<A> SpState

SpState

 ResponsePacketAssembler (Port<A>& port)

ResponsePacketAssembler

Constructor.

Parameters:

portPort to take configuration information from.
 ResponsePacketAssembler (SpState& sp)

ResponsePacketAssembler

Constructor.

Parameters:

spSpecialized state.
 ~ResponsePacketAssembler ()

~ResponsePacketAssembler

Destructor.

void  packet_start (RipPacket<A>* pkt)

packet_start

Start assembling RIP response packet.

bool  packet_add_route (const Net& net, const Addr& nexthop, uint16_t cost, uint16_t tag)

packet_add_route

Add a route to RIP response packet.

Returns: true if route was added, false if packet is full and would have indicated this if only packet_full was called.

bool  packet_full ()

packet_full

[const]

Ready-to-go accessor.

Returns: true if packet has no more space for route entries.

bool  packet_finish (list<RipPacket<A>* >& auth_packets)

packet_finish

Finish packet. Some packet types require final stage processing and this method gives that processing a chance to happen. Common usage is RIPv2 authentication.

Parameters:

auth_packetsa return-by-reference list with the authenticated RIP packets (one copy for each valid authentication key).

Returns: true on success, false if a failure is detected.

RipPacket<A>* _pkt

_pkt

[protected]

uint32_t _pos

_pos

[protected]

SpState _sp_state

_sp_state

[protected]

template <> inline  ResponsePacketAssembler (Port<IPv4>& port)

ResponsePacketAssembler

[protected]

template <> inline  ResponsePacketAssembler (SpState& sp)

ResponsePacketAssembler

[protected]

template <> inline  ~ResponsePacketAssembler ()

~ResponsePacketAssembler

[protected]

template <> inline void  packet_start (RipPacket<IPv4>* pkt)

packet_start

[protected]

template <> inline bool  packet_full ()

packet_full

[protected const]

template <> inline bool  packet_add_route (const Net& net, const Addr& nexthop, uint16_t cost, uint16_t tag)

packet_add_route

[protected]

template <> inline bool  packet_finish ( list<RipPacket<IPv4>* >& auth_packets)

packet_finish

[protected]

template <> inline  ResponsePacketAssembler (Port<IPv6>& port)

ResponsePacketAssembler

[protected]

template <> inline  ResponsePacketAssembler (SpState& sp)

ResponsePacketAssembler

[protected]

template <> inline  ~ResponsePacketAssembler ()

~ResponsePacketAssembler

[protected]

template <> inline void  packet_start (RipPacket<IPv6>* pkt)

packet_start

[protected]

template <> inline bool  packet_full ()

packet_full

[protected const]

template <> inline bool  packet_add_route (const Net& net, const Addr& nexthop, uint16_t cost, uint16_t tag)

packet_add_route

[protected]

template <> inline bool  packet_finish ( list<RipPacket<IPv6>* >& auth_packets)

packet_finish

[protected]


Generated by: bms on anglepoise.lon.incunabulum.net on Wed Jul 23 10:06:09 2008, using kdoc 2.0a54+XORP.