FD.io VPP  v21.10.1-2-g0a485f517
Vector Packet Processing
VOM::route::ip_route Class Reference

A IP route. More...

+ Inheritance diagram for VOM::route::ip_route:
+ Collaboration diagram for VOM::route::ip_route:

Public Types

typedef std::pair< route::table_id_t, prefix_tkey_t
 The key for a route. More...
 

Public Member Functions

 ip_route (const prefix_t &prefix)
 Construct a route in the default table. More...
 
 ip_route (const prefix_t &prefix, const path &p)
 Construct a route with a path. More...
 
 ip_route (const ip_route &r)
 Copy Construct. More...
 
 ip_route (const route_domain &rd, const prefix_t &prefix)
 Construct a route in the given route domain. More...
 
 ip_route (const route_domain &rd, const prefix_t &prefix, const path &p)
 Construct a route in the given route domain with a path. More...
 
 ~ip_route ()
 Destructor. More...
 
const key_t key () const
 Get the route's key. More...
 
bool operator== (const ip_route &i) const
 Comparison operator. More...
 
std::shared_ptr< ip_routesingular () const
 Return the matching 'singular instance'. More...
 
void add (const path &path)
 Add a path. More...
 
void remove (const path &path)
 remove a path. More...
 
void replay (void)
 replay the object to create it in hardware More...
 
std::string to_string () const
 Convert to string for debugging. More...
 

Static Public Member Functions

static std::shared_ptr< ip_routefind (const ip_route &temp)
 Find the instnace of the route domain in the OM. More...
 
static void dump (std::ostream &os)
 Dump all route-doamin into the stream provided. More...
 
static std::shared_ptr< ip_routefind (const key_t &k)
 Return the matching 'singular instance'. More...
 

Friends

class VOM::OM
 
class singular_db< key_t, ip_route >
 It's the singular_db class that calls replay() More...
 

Additional Inherited Members

- Protected Member Functions inherited from VOM::object_base
 object_base ()=default
 Constructable by derived classes only. More...
 
virtual ~object_base ()=default
 Destructor. More...
 

Detailed Description

A IP route.

Definition at line 247 of file route.hpp.

Member Typedef Documentation

◆ key_t

The key for a route.

Definition at line 253 of file route.hpp.

Constructor & Destructor Documentation

◆ ip_route() [1/5]

VOM::route::ip_route::ip_route ( const prefix_t prefix)

Construct a route in the default table.

Definition at line 263 of file route.cpp.

◆ ip_route() [2/5]

VOM::route::ip_route::ip_route ( const prefix_t prefix,
const path p 
)

Construct a route with a path.

Definition at line 255 of file route.cpp.

◆ ip_route() [3/5]

VOM::route::ip_route::ip_route ( const ip_route r)

Copy Construct.

Definition at line 271 of file route.cpp.

◆ ip_route() [4/5]

VOM::route::ip_route::ip_route ( const route_domain rd,
const prefix_t prefix 
)

Construct a route in the given route domain.

Definition at line 279 of file route.cpp.

◆ ip_route() [5/5]

VOM::route::ip_route::ip_route ( const route_domain rd,
const prefix_t prefix,
const path p 
)

Construct a route in the given route domain with a path.

Definition at line 287 of file route.cpp.

◆ ~ip_route()

VOM::route::ip_route::~ip_route ( )

Destructor.

Definition at line 297 of file route.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ add()

void VOM::route::ip_route::add ( const path path)

Add a path.

Definition at line 319 of file route.cpp.

◆ dump()

void VOM::route::ip_route::dump ( std::ostream &  os)
static

Dump all route-doamin into the stream provided.

Definition at line 386 of file route.cpp.

+ Here is the call graph for this function:

◆ find() [1/2]

static std::shared_ptr<ip_route> VOM::route::ip_route::find ( const ip_route temp)
static

Find the instnace of the route domain in the OM.

◆ find() [2/2]

std::shared_ptr< ip_route > VOM::route::ip_route::find ( const key_t k)
static

Return the matching 'singular instance'.

Definition at line 374 of file route.cpp.

◆ key()

const ip_route::key_t VOM::route::ip_route::key ( ) const

Get the route's key.

Definition at line 307 of file route.cpp.

+ Here is the caller graph for this function:

◆ operator==()

bool VOM::route::ip_route::operator== ( const ip_route i) const

Comparison operator.

Definition at line 313 of file route.cpp.

+ Here is the call graph for this function:

◆ remove()

void VOM::route::ip_route::remove ( const path path)

remove a path.

Definition at line 325 of file route.cpp.

◆ replay()

void VOM::route::ip_route::replay ( void  )
virtual

replay the object to create it in hardware

Implements VOM::object_base.

Definition at line 341 of file route.cpp.

+ Here is the call graph for this function:

◆ singular()

std::shared_ptr< ip_route > VOM::route::ip_route::singular ( ) const

Return the matching 'singular instance'.

Definition at line 380 of file route.cpp.

◆ to_string()

std::string VOM::route::ip_route::to_string ( ) const
virtual

Convert to string for debugging.

Implements VOM::object_base.

Definition at line 349 of file route.cpp.

+ Here is the call graph for this function:

Friends And Related Function Documentation

◆ singular_db< key_t, ip_route >

friend class singular_db< key_t, ip_route >
friend

It's the singular_db class that calls replay()

Definition at line 384 of file route.hpp.

◆ VOM::OM

friend class VOM::OM
friend

Definition at line 379 of file route.hpp.


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