xorp

Protocol Class Reference

Routing protocol information. More...

#include <protocol.hh>

List of all members.

Public Member Functions

 Protocol (const string &name, ProtocolType protocol_type, uint32_t genid)
 Protocol constuctor.
ProtocolType protocol_type () const
const string & name () const
bool operator== (const Protocol &other) const
 Equality Operator.
void increment_genid ()
 Increment the protocol generation ID.

Private Attributes

string _name
ProtocolType _protocol_type
uint32_t _genid

Detailed Description

Routing protocol information.

Protocol holds information related to a specific routing protocol that is supplying information to the RIB.


Constructor & Destructor Documentation

Protocol::Protocol ( const string &  name,
ProtocolType  protocol_type,
uint32_t  genid 
)

Protocol constuctor.

Parameters:
namethe canonical name for the routing protocol.
protocol_typethe routing protocol type (ProtocolType).
genidthe generation ID for the protocol (if the protocol goes down and comes up, the genid should be incremented).

Member Function Documentation

const string& Protocol::name ( ) const [inline]
Returns:
the canonical name of the routing protocol.
bool Protocol::operator== ( const Protocol other) const [inline]

Equality Operator.

Two Protocol instances are equal if they match only in name.

Parameters:
otherthe right-hand operand to compare against.
Returns:
true if the left-hand Protocol instance is equal to the right-hand protocol instance.
ProtocolType Protocol::protocol_type ( ) const [inline]
Returns:
the protocol type.
See also:
ProtocolType

The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Typedefs Enumerations