OpenSDN source code
MatchCommunity Class Reference

#include <routing_policy_match.h>

Inheritance diagram for MatchCommunity:
Collaboration diagram for MatchCommunity:

Public Types

typedef std::set< uint32_t > CommunityList
 
typedef std::vector< std::string > CommunityRegexStringList
 
typedef std::vector< contrail::regexCommunityRegexList
 

Public Member Functions

 MatchCommunity (const std::vector< std::string > &communities, bool match_all)
 
virtual ~MatchCommunity ()
 
virtual bool Match (const BgpRoute *route, const BgpPath *path, const BgpAttr *attr) const
 
virtual std::string ToString () const
 
virtual bool IsEqual (const RoutingPolicyMatch &community) const
 
bool match_all () const
 
const CommunityListcommunities () const
 
const CommunityRegexStringListregex_strings () const
 
const CommunityRegexListregexs () const
 
- Public Member Functions inherited from RoutingPolicyMatch
virtual ~RoutingPolicyMatch ()
 
bool operator() (const BgpRoute *route, const BgpPath *path, const BgpAttr *attr) const
 
virtual bool operator== (const RoutingPolicyMatch &match) const
 
virtual bool operator!= (const RoutingPolicyMatch &match) const
 

Private Member Functions

bool MatchAll (const BgpAttr *attr) const
 
bool MatchAny (const BgpAttr *attr) const
 

Private Attributes

bool match_all_
 
CommunityList to_match_
 
CommunityRegexStringList to_match_regex_strings_
 
CommunityRegexList to_match_regexs_
 

Detailed Description

Definition at line 48 of file routing_policy_match.h.

Member Typedef Documentation

◆ CommunityList

typedef std::set<uint32_t> MatchCommunity::CommunityList

Definition at line 50 of file routing_policy_match.h.

◆ CommunityRegexList

Definition at line 52 of file routing_policy_match.h.

◆ CommunityRegexStringList

typedef std::vector<std::string> MatchCommunity::CommunityRegexStringList

Definition at line 51 of file routing_policy_match.h.

Constructor & Destructor Documentation

◆ MatchCommunity()

MatchCommunity::MatchCommunity ( const std::vector< std::string > &  communities,
bool  match_all 
)

Definition at line 50 of file routing_policy_match.cc.

Here is the call graph for this function:

◆ ~MatchCommunity()

MatchCommunity::~MatchCommunity ( )
virtual

Definition at line 75 of file routing_policy_match.cc.

Member Function Documentation

◆ communities()

const CommunityList& MatchCommunity::communities ( ) const
inline

Definition at line 61 of file routing_policy_match.h.

◆ IsEqual()

bool MatchCommunity::IsEqual ( const RoutingPolicyMatch community) const
virtual

Implements RoutingPolicyMatch.

Definition at line 178 of file routing_policy_match.cc.

Here is the call graph for this function:

◆ Match()

bool MatchCommunity::Match ( const BgpRoute route,
const BgpPath path,
const BgpAttr attr 
) const
virtual

Implements RoutingPolicyMatch.

Definition at line 148 of file routing_policy_match.cc.

Here is the call graph for this function:

◆ match_all()

bool MatchCommunity::match_all ( ) const
inline

Definition at line 60 of file routing_policy_match.h.

◆ MatchAll()

bool MatchCommunity::MatchAll ( const BgpAttr attr) const
private

Definition at line 82 of file routing_policy_match.cc.

Here is the call graph for this function:

◆ MatchAny()

bool MatchCommunity::MatchAny ( const BgpAttr attr) const
private

Definition at line 119 of file routing_policy_match.cc.

Here is the call graph for this function:

◆ regex_strings()

const CommunityRegexStringList& MatchCommunity::regex_strings ( ) const
inline

Definition at line 62 of file routing_policy_match.h.

◆ regexs()

const CommunityRegexList& MatchCommunity::regexs ( ) const
inline

Definition at line 65 of file routing_policy_match.h.

◆ ToString()

string MatchCommunity::ToString ( ) const
virtual

Implements RoutingPolicyMatch.

Definition at line 156 of file routing_policy_match.cc.

Here is the call graph for this function:

Member Data Documentation

◆ match_all_

bool MatchCommunity::match_all_
private

Definition at line 71 of file routing_policy_match.h.

◆ to_match_

CommunityList MatchCommunity::to_match_
private

Definition at line 72 of file routing_policy_match.h.

◆ to_match_regex_strings_

CommunityRegexStringList MatchCommunity::to_match_regex_strings_
private

Definition at line 73 of file routing_policy_match.h.

◆ to_match_regexs_

CommunityRegexList MatchCommunity::to_match_regexs_
private

Definition at line 74 of file routing_policy_match.h.


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