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

#include <bgp_attr.h>

Collaboration diagram for BgpAttr:

Public Member Functions

 BgpAttr ()
 
 BgpAttr (BgpAttrDB *attr_db)
 
 BgpAttr (const BgpAttr &rhs)
 
 BgpAttr (BgpAttrDB *attr_db, const BgpAttrSpec &spec)
 
virtual ~BgpAttr ()
 
virtual void Remove ()
 
int CompareTo (const BgpAttr &rhs) const
 
void set_origin (BgpAttrOrigin::OriginType org)
 
void set_nexthop (IpAddress nexthop)
 
void set_med (uint32_t med)
 
void set_local_pref (uint32_t local_pref)
 
void set_atomic_aggregate (bool ae)
 
void set_aggregator (as_t as_num, IpAddress address)
 
void set_as4_aggregator (as_t as_num, IpAddress address)
 
void set_originator_id (Ip4Address originator_id)
 
void set_source_rd (const RouteDistinguisher &source_rd)
 
void set_esi (const EthernetSegmentId &esi)
 
void set_params (uint64_t params)
 
void set_as_path (AsPathPtr aspath)
 
void set_as_path (const AsPathSpec *spec)
 
void set_as4_path (As4PathPtr aspath)
 
void set_as4_path (const As4PathSpec *spec)
 
void set_aspath_4byte (AsPath4BytePtr aspath)
 
void set_aspath_4byte (const AsPath4ByteSpec *spec)
 
void set_cluster_list (const ClusterListSpec *spec)
 
void set_community (CommunityPtr comm)
 
void set_community (const CommunitySpec *comm)
 
void set_ext_community (ExtCommunityPtr extcomm)
 
void set_ext_community (const ExtCommunitySpec *extcomm)
 
void set_origin_vn_path (OriginVnPathPtr ovnpath)
 
void set_origin_vn_path (const OriginVnPathSpec *spec)
 
void set_pmsi_tunnel (const PmsiTunnelSpec *pmsi_spec)
 
void set_edge_discovery (const EdgeDiscoverySpec *edspec)
 
void set_edge_forwarding (const EdgeForwardingSpec *efspec)
 
void set_label_block (LabelBlockPtr label_block)
 
void set_olist (const BgpOListSpec *olist_spec)
 
void set_leaf_olist (const BgpOListSpec *leaf_olist_spec)
 
void set_sub_protocol (const std::string &sub_protocol)
 
BgpAttrOrigin::OriginType origin () const
 
std::string origin_string () const
 
const IpAddressnexthop () const
 
Address::Family nexthop_family () const
 
uint32_t med () const
 
uint32_t local_pref () const
 
bool atomic_aggregate () const
 
as_t aggregator_as_num () const
 
as_t aggregator_as4_num () const
 
as_t neighbor_as () const
 
const IpAddressaggregator_adderess () const
 
const Ip4Addressoriginator_id () const
 
const RouteDistinguishersource_rd () const
 
const EthernetSegmentIdesi () const
 
uint64_t params () const
 
const AsPathas_path () const
 
int as_path_count () const
 
int max_as_path_count () const
 
const AsPath4Byteaspath_4byte () const
 
int aspath_4byte_count () const
 
int IsAsPathLoop (as_t asn, uint8_t max_loop_count=0) const
 
const ClusterListcluster_list () const
 
size_t cluster_list_length () const
 
const As4Pathas4_path () const
 
int as4_path_count () const
 
bool IsAsPathEmpty () const
 
const Communitycommunity () const
 
const ExtCommunityext_community () const
 
const OriginVnPathorigin_vn_path () const
 
const PmsiTunnelpmsi_tunnel () const
 
const EdgeDiscoveryedge_discovery () const
 
const EdgeForwardingedge_forwarding () const
 
LabelBlockPtr label_block () const
 
BgpOListPtr olist () const
 
BgpOListPtr leaf_olist () const
 
const std::string & sub_protocol () const
 
BgpAttrDBattr_db ()
 
const BgpAttrDBattr_db () const
 
uint32_t sequence_number () const
 
bool evpn_sticky_mac () const
 
bool etree_leaf () const
 
bool evpn_single_active () const
 
MacAddress mac_address () const
 

Static Public Member Functions

static std::string OriginToString (BgpAttrOrigin::OriginType origin)
 
static BgpAttrOrigin::OriginType OriginFromString (const std::string &bgp_origin_type)
 

Private Attributes

tbb::atomic< int > refcount_
 
BgpAttrDBattr_db_
 
BgpAttrOrigin::OriginType origin_
 
IpAddress nexthop_
 
uint32_t med_
 
uint32_t local_pref_
 
bool atomic_aggregate_
 
as_t aggregator_as_num_
 
as_t aggregator_as4_num_
 
IpAddress aggregator_address_
 
Ip4Address originator_id_
 
RouteDistinguisher source_rd_
 
EthernetSegmentId esi_
 
uint64_t params_
 
AsPathPtr as_path_
 
AsPath4BytePtr aspath_4byte_
 
As4PathPtr as4_path_
 
ClusterListPtr cluster_list_
 
CommunityPtr community_
 
ExtCommunityPtr ext_community_
 
OriginVnPathPtr origin_vn_path_
 
PmsiTunnelPtr pmsi_tunnel_
 
EdgeDiscoveryPtr edge_discovery_
 
EdgeForwardingPtr edge_forwarding_
 
LabelBlockPtr label_block_
 
BgpOListPtr olist_
 
BgpOListPtr leaf_olist_
 
std::string sub_protocol_
 

Friends

class BgpAttrDB
 
class BgpAttrTest
 
std::size_t hash_value (BgpAttr const &attr)
 
int intrusive_ptr_add_ref (const BgpAttr *cattrp)
 
int intrusive_ptr_del_ref (const BgpAttr *cattrp)
 
void intrusive_ptr_release (const BgpAttr *cattrp)
 

Detailed Description

Definition at line 825 of file bgp_attr.h.

Constructor & Destructor Documentation

BgpAttr::BgpAttr ( )

Definition at line 901 of file bgp_attr.cc.

BgpAttr::BgpAttr ( BgpAttrDB attr_db)
explicit

Definition at line 908 of file bgp_attr.cc.

BgpAttr::BgpAttr ( const BgpAttr rhs)
explicit

Definition at line 929 of file bgp_attr.cc.

BgpAttr::BgpAttr ( BgpAttrDB attr_db,
const BgpAttrSpec spec 
)

Definition at line 915 of file bgp_attr.cc.

virtual BgpAttr::~BgpAttr ( )
inlinevirtual

Definition at line 831 of file bgp_attr.h.

Member Function Documentation

const IpAddress& BgpAttr::aggregator_adderess ( ) const
inline

Definition at line 894 of file bgp_attr.h.

as_t BgpAttr::aggregator_as4_num ( ) const
inline

Definition at line 892 of file bgp_attr.h.

as_t BgpAttr::aggregator_as_num ( ) const
inline

Definition at line 891 of file bgp_attr.h.

const As4Path* BgpAttr::as4_path ( ) const
inline

Definition at line 911 of file bgp_attr.h.

int BgpAttr::as4_path_count ( ) const
inline

Definition at line 912 of file bgp_attr.h.

const AsPath* BgpAttr::as_path ( ) const
inline

Definition at line 899 of file bgp_attr.h.

int BgpAttr::as_path_count ( ) const
inline

Definition at line 900 of file bgp_attr.h.

const AsPath4Byte* BgpAttr::aspath_4byte ( ) const
inline

Definition at line 902 of file bgp_attr.h.

int BgpAttr::aspath_4byte_count ( ) const
inline

Definition at line 903 of file bgp_attr.h.

bool BgpAttr::atomic_aggregate ( ) const
inline

Definition at line 890 of file bgp_attr.h.

BgpAttrDB* BgpAttr::attr_db ( )
inline

Definition at line 928 of file bgp_attr.h.

const BgpAttrDB* BgpAttr::attr_db ( ) const
inline

Definition at line 929 of file bgp_attr.h.

const ClusterList* BgpAttr::cluster_list ( ) const
inline

Definition at line 907 of file bgp_attr.h.

size_t BgpAttr::cluster_list_length ( ) const
inline

Definition at line 908 of file bgp_attr.h.

const Community* BgpAttr::community ( ) const
inline

Definition at line 914 of file bgp_attr.h.

int BgpAttr::CompareTo ( const BgpAttr rhs) const

Definition at line 1229 of file bgp_attr.cc.

const EdgeDiscovery* BgpAttr::edge_discovery ( ) const
inline

Definition at line 918 of file bgp_attr.h.

const EdgeForwarding* BgpAttr::edge_forwarding ( ) const
inline

Definition at line 921 of file bgp_attr.h.

const EthernetSegmentId& BgpAttr::esi ( ) const
inline

Definition at line 897 of file bgp_attr.h.

bool BgpAttr::etree_leaf ( ) const

Definition at line 1168 of file bgp_attr.cc.

Here is the call graph for this function:

bool BgpAttr::evpn_single_active ( ) const

Definition at line 1182 of file bgp_attr.cc.

Here is the call graph for this function:

bool BgpAttr::evpn_sticky_mac ( ) const

Definition at line 1154 of file bgp_attr.cc.

Here is the call graph for this function:

const ExtCommunity* BgpAttr::ext_community ( ) const
inline

Definition at line 915 of file bgp_attr.h.

bool BgpAttr::IsAsPathEmpty ( ) const

Definition at line 1087 of file bgp_attr.cc.

int BgpAttr::IsAsPathLoop ( as_t  asn,
uint8_t  max_loop_count = 0 
) const

Definition at line 1214 of file bgp_attr.cc.

Here is the call graph for this function:

LabelBlockPtr BgpAttr::label_block ( ) const
inline

Definition at line 924 of file bgp_attr.h.

BgpOListPtr BgpAttr::leaf_olist ( ) const
inline

Definition at line 926 of file bgp_attr.h.

uint32_t BgpAttr::local_pref ( ) const
inline

Definition at line 889 of file bgp_attr.h.

MacAddress BgpAttr::mac_address ( ) const

Definition at line 1196 of file bgp_attr.cc.

Here is the call graph for this function:

int BgpAttr::max_as_path_count ( ) const

Definition at line 1081 of file bgp_attr.cc.

Here is the call graph for this function:

uint32_t BgpAttr::med ( ) const
inline

Definition at line 888 of file bgp_attr.h.

as_t BgpAttr::neighbor_as ( ) const

Definition at line 1132 of file bgp_attr.cc.

const IpAddress& BgpAttr::nexthop ( ) const
inline

Definition at line 886 of file bgp_attr.h.

Address::Family BgpAttr::nexthop_family ( ) const

Definition at line 1124 of file bgp_attr.cc.

BgpOListPtr BgpAttr::olist ( ) const
inline

Definition at line 925 of file bgp_attr.h.

BgpAttrOrigin::OriginType BgpAttr::origin ( ) const
inline

Definition at line 881 of file bgp_attr.h.

string BgpAttr::origin_string ( ) const

Definition at line 1120 of file bgp_attr.cc.

Here is the call graph for this function:

const OriginVnPath* BgpAttr::origin_vn_path ( ) const
inline

Definition at line 916 of file bgp_attr.h.

const Ip4Address& BgpAttr::originator_id ( ) const
inline

Definition at line 895 of file bgp_attr.h.

BgpAttrOrigin::OriginType BgpAttr::OriginFromString ( const std::string &  bgp_origin_type)
static

Definition at line 1110 of file bgp_attr.cc.

string BgpAttr::OriginToString ( BgpAttrOrigin::OriginType  origin)
static

Definition at line 1095 of file bgp_attr.cc.

uint64_t BgpAttr::params ( ) const
inline

Definition at line 898 of file bgp_attr.h.

const PmsiTunnel* BgpAttr::pmsi_tunnel ( ) const
inline

Definition at line 917 of file bgp_attr.h.

void BgpAttr::Remove ( )
virtual

Definition at line 1210 of file bgp_attr.cc.

Here is the call graph for this function:

uint32_t BgpAttr::sequence_number ( ) const

Definition at line 1140 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_aggregator ( as_t  as_num,
IpAddress  address 
)
inline

Definition at line 841 of file bgp_attr.h.

void BgpAttr::set_as4_aggregator ( as_t  as_num,
IpAddress  address 
)
inline

Definition at line 845 of file bgp_attr.h.

void BgpAttr::set_as4_path ( As4PathPtr  aspath)

Definition at line 967 of file bgp_attr.cc.

void BgpAttr::set_as4_path ( const As4PathSpec spec)

Definition at line 971 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_as_path ( AsPathPtr  aspath)

Definition at line 955 of file bgp_attr.cc.

void BgpAttr::set_as_path ( const AsPathSpec spec)

Definition at line 959 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_aspath_4byte ( AsPath4BytePtr  aspath)

Definition at line 979 of file bgp_attr.cc.

void BgpAttr::set_aspath_4byte ( const AsPath4ByteSpec spec)

Definition at line 983 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_atomic_aggregate ( bool  ae)
inline

Definition at line 840 of file bgp_attr.h.

void BgpAttr::set_cluster_list ( const ClusterListSpec spec)

Definition at line 991 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_community ( CommunityPtr  comm)

Definition at line 999 of file bgp_attr.cc.

void BgpAttr::set_community ( const CommunitySpec comm)

Definition at line 1003 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_edge_discovery ( const EdgeDiscoverySpec edspec)

Definition at line 1043 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_edge_forwarding ( const EdgeForwardingSpec efspec)

Definition at line 1052 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_esi ( const EthernetSegmentId esi)
inline

Definition at line 855 of file bgp_attr.h.

Here is the call graph for this function:

void BgpAttr::set_ext_community ( ExtCommunityPtr  extcomm)

Definition at line 1011 of file bgp_attr.cc.

void BgpAttr::set_ext_community ( const ExtCommunitySpec extcomm)

Definition at line 1015 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_label_block ( LabelBlockPtr  label_block)

Definition at line 1061 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_leaf_olist ( const BgpOListSpec leaf_olist_spec)

Definition at line 1073 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_local_pref ( uint32_t  local_pref)
inline

Definition at line 839 of file bgp_attr.h.

Here is the call graph for this function:

void BgpAttr::set_med ( uint32_t  med)
inline

Definition at line 838 of file bgp_attr.h.

Here is the call graph for this function:

void BgpAttr::set_nexthop ( IpAddress  nexthop)
inline

Definition at line 837 of file bgp_attr.h.

Here is the call graph for this function:

void BgpAttr::set_olist ( const BgpOListSpec olist_spec)

Definition at line 1065 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_origin ( BgpAttrOrigin::OriginType  org)
inline

Definition at line 836 of file bgp_attr.h.

void BgpAttr::set_origin_vn_path ( OriginVnPathPtr  ovnpath)

Definition at line 1023 of file bgp_attr.cc.

void BgpAttr::set_origin_vn_path ( const OriginVnPathSpec spec)

Definition at line 1027 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_originator_id ( Ip4Address  originator_id)
inline

Definition at line 849 of file bgp_attr.h.

Here is the call graph for this function:

void BgpAttr::set_params ( uint64_t  params)
inline

Definition at line 856 of file bgp_attr.h.

Here is the call graph for this function:

void BgpAttr::set_pmsi_tunnel ( const PmsiTunnelSpec pmsi_spec)

Definition at line 1035 of file bgp_attr.cc.

Here is the call graph for this function:

void BgpAttr::set_source_rd ( const RouteDistinguisher source_rd)
inline

Definition at line 852 of file bgp_attr.h.

Here is the call graph for this function:

void BgpAttr::set_sub_protocol ( const std::string &  sub_protocol)
inline

Definition at line 876 of file bgp_attr.h.

Here is the call graph for this function:

const RouteDistinguisher& BgpAttr::source_rd ( ) const
inline

Definition at line 896 of file bgp_attr.h.

const std::string& BgpAttr::sub_protocol ( ) const
inline

Definition at line 927 of file bgp_attr.h.

Friends And Related Function Documentation

friend class BgpAttrDB
friend

Definition at line 937 of file bgp_attr.h.

friend class BgpAttrTest
friend

Definition at line 938 of file bgp_attr.h.

std::size_t hash_value ( BgpAttr const &  attr)
friend

Definition at line 1259 of file bgp_attr.cc.

int intrusive_ptr_add_ref ( const BgpAttr cattrp)
friend

Definition at line 973 of file bgp_attr.h.

int intrusive_ptr_del_ref ( const BgpAttr cattrp)
friend

Definition at line 977 of file bgp_attr.h.

void intrusive_ptr_release ( const BgpAttr cattrp)
friend

Definition at line 981 of file bgp_attr.h.

Member Data Documentation

IpAddress BgpAttr::aggregator_address_
private

Definition at line 952 of file bgp_attr.h.

as_t BgpAttr::aggregator_as4_num_
private

Definition at line 951 of file bgp_attr.h.

as_t BgpAttr::aggregator_as_num_
private

Definition at line 950 of file bgp_attr.h.

As4PathPtr BgpAttr::as4_path_
private

Definition at line 959 of file bgp_attr.h.

AsPathPtr BgpAttr::as_path_
private

Definition at line 957 of file bgp_attr.h.

AsPath4BytePtr BgpAttr::aspath_4byte_
private

Definition at line 958 of file bgp_attr.h.

bool BgpAttr::atomic_aggregate_
private

Definition at line 949 of file bgp_attr.h.

BgpAttrDB* BgpAttr::attr_db_
private

Definition at line 944 of file bgp_attr.h.

ClusterListPtr BgpAttr::cluster_list_
private

Definition at line 960 of file bgp_attr.h.

CommunityPtr BgpAttr::community_
private

Definition at line 961 of file bgp_attr.h.

EdgeDiscoveryPtr BgpAttr::edge_discovery_
private

Definition at line 965 of file bgp_attr.h.

EdgeForwardingPtr BgpAttr::edge_forwarding_
private

Definition at line 966 of file bgp_attr.h.

EthernetSegmentId BgpAttr::esi_
private

Definition at line 955 of file bgp_attr.h.

ExtCommunityPtr BgpAttr::ext_community_
private

Definition at line 962 of file bgp_attr.h.

LabelBlockPtr BgpAttr::label_block_
private

Definition at line 967 of file bgp_attr.h.

BgpOListPtr BgpAttr::leaf_olist_
private

Definition at line 969 of file bgp_attr.h.

uint32_t BgpAttr::local_pref_
private

Definition at line 948 of file bgp_attr.h.

uint32_t BgpAttr::med_
private

Definition at line 947 of file bgp_attr.h.

IpAddress BgpAttr::nexthop_
private

Definition at line 946 of file bgp_attr.h.

BgpOListPtr BgpAttr::olist_
private

Definition at line 968 of file bgp_attr.h.

BgpAttrOrigin::OriginType BgpAttr::origin_
private

Definition at line 945 of file bgp_attr.h.

OriginVnPathPtr BgpAttr::origin_vn_path_
private

Definition at line 963 of file bgp_attr.h.

Ip4Address BgpAttr::originator_id_
private

Definition at line 953 of file bgp_attr.h.

uint64_t BgpAttr::params_
private

Definition at line 956 of file bgp_attr.h.

PmsiTunnelPtr BgpAttr::pmsi_tunnel_
private

Definition at line 964 of file bgp_attr.h.

tbb::atomic<int> BgpAttr::refcount_
mutableprivate

Definition at line 943 of file bgp_attr.h.

RouteDistinguisher BgpAttr::source_rd_
private

Definition at line 954 of file bgp_attr.h.

std::string BgpAttr::sub_protocol_
private

Definition at line 970 of file bgp_attr.h.


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