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

#include <rd.h>

Collaboration diagram for RouteDistinguisher:

Public Types

enum  RDType { Type2ByteASBased = 0, TypeIpAddressBased = 1, Type4ByteASBased = 2 }
 

Public Member Functions

 RouteDistinguisher ()
 
 RouteDistinguisher (const uint8_t *data)
 
 RouteDistinguisher (uint32_t address, uint16_t vrf_id)
 
 RouteDistinguisher (uint16_t cluster_seed, uint32_t address, uint16_t vrf_id)
 
 RouteDistinguisher (bool is_bgpaas, uint32_t asn, uint16_t vmi_index)
 
 RouteDistinguisher (const RouteDistinguisher &rhs)
 
std::string ToString () const
 
RouteDistinguisheroperator= (const RouteDistinguisher &rhs)
 
bool IsZero () const
 
uint16_t Type () const
 
uint32_t GetAddress () const
 
uint16_t GetVrfId () const
 
int CompareTo (const RouteDistinguisher &rhs) const
 
bool operator== (const RouteDistinguisher &rhs) const
 
bool operator< (const RouteDistinguisher &rhs) const
 
bool operator> (const RouteDistinguisher &rhs) const
 
const uint8_t * GetData () const
 

Static Public Member Functions

static RouteDistinguisher FromString (const std::string &str, boost::system::error_code *error=NULL)
 

Static Public Attributes

static const size_t kSize = 8
 
static RouteDistinguisher kZeroRd
 

Private Attributes

uint8_t data_ [kSize]
 

Detailed Description

Definition at line 11 of file rd.h.

Member Enumeration Documentation

Enumerator
Type2ByteASBased 
TypeIpAddressBased 
Type4ByteASBased 

Definition at line 16 of file rd.h.

Constructor & Destructor Documentation

RouteDistinguisher::RouteDistinguisher ( )

Definition at line 16 of file rd.cc.

RouteDistinguisher::RouteDistinguisher ( const uint8_t *  data)
explicit

Definition at line 20 of file rd.cc.

RouteDistinguisher::RouteDistinguisher ( uint32_t  address,
uint16_t  vrf_id 
)

Definition at line 24 of file rd.cc.

Here is the call graph for this function:

RouteDistinguisher::RouteDistinguisher ( uint16_t  cluster_seed,
uint32_t  address,
uint16_t  vrf_id 
)

Definition at line 36 of file rd.cc.

Here is the call graph for this function:

RouteDistinguisher::RouteDistinguisher ( bool  is_bgpaas,
uint32_t  asn,
uint16_t  vmi_index 
)

Definition at line 30 of file rd.cc.

Here is the call graph for this function:

RouteDistinguisher::RouteDistinguisher ( const RouteDistinguisher rhs)
inline

Definition at line 29 of file rd.h.

Member Function Documentation

int RouteDistinguisher::CompareTo ( const RouteDistinguisher rhs) const

Definition at line 157 of file rd.cc.

RouteDistinguisher RouteDistinguisher::FromString ( const std::string &  str,
boost::system::error_code *  error = NULL 
)
static

Definition at line 83 of file rd.cc.

Here is the call graph for this function:

uint32_t RouteDistinguisher::GetAddress ( ) const

Definition at line 48 of file rd.cc.

Here is the call graph for this function:

const uint8_t* RouteDistinguisher::GetData ( ) const
inline

Definition at line 59 of file rd.h.

uint16_t RouteDistinguisher::GetVrfId ( ) const

Definition at line 52 of file rd.cc.

Here is the call graph for this function:

bool RouteDistinguisher::IsZero ( ) const
inline

Definition at line 43 of file rd.h.

Here is the call graph for this function:

bool RouteDistinguisher::operator< ( const RouteDistinguisher rhs) const
inline

Definition at line 52 of file rd.h.

Here is the call graph for this function:

RouteDistinguisher& RouteDistinguisher::operator= ( const RouteDistinguisher rhs)
inline

Definition at line 38 of file rd.h.

bool RouteDistinguisher::operator== ( const RouteDistinguisher rhs) const
inline

Definition at line 49 of file rd.h.

Here is the call graph for this function:

bool RouteDistinguisher::operator> ( const RouteDistinguisher rhs) const
inline

Definition at line 55 of file rd.h.

Here is the call graph for this function:

string RouteDistinguisher::ToString ( ) const

Definition at line 56 of file rd.cc.

Here is the call graph for this function:

uint16_t RouteDistinguisher::Type ( ) const

Definition at line 44 of file rd.cc.

Here is the call graph for this function:

Member Data Documentation

uint8_t RouteDistinguisher::data_[kSize]
private

Definition at line 62 of file rd.h.

const size_t RouteDistinguisher::kSize = 8
static

Definition at line 13 of file rd.h.

RouteDistinguisher RouteDistinguisher::kZeroRd
static

Definition at line 14 of file rd.h.


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