FD.io VPP  v18.01.2-1-g9b554f3
Vector Packet Processing
VOM::object_ref Class Reference

A represenation of a reference to a VPP object. More...

Public Member Functions

 object_ref (std::shared_ptr< object_base > obj)
 Constructor. More...
 
bool operator< (const object_ref &other) const
 less than operator More...
 
std::shared_ptr< object_baseobj () const
 Return the shared pointer. More...
 
void mark () const
 Mark the reference object as stale. More...
 
void clear () const
 Clear the stale flag on the object. More...
 
bool stale () const
 Query if the object is stale. More...
 

Detailed Description

A represenation of a reference to a VPP object.

the reference counting is held through the use of shared pointers. We also maintain the state of the object ready for mark n' sweep.

Definition at line 86 of file object_base.hpp.

Constructor & Destructor Documentation

VOM::object_ref::object_ref ( std::shared_ptr< object_base obj)

Constructor.

Definition at line 19 of file object_base.cpp.

Member Function Documentation

void VOM::object_ref::clear ( ) const

Clear the stale flag on the object.

Definition at line 44 of file object_base.cpp.

void VOM::object_ref::mark ( ) const

Mark the reference object as stale.

Definition at line 38 of file object_base.cpp.

std::shared_ptr< object_base > VOM::object_ref::obj ( ) const

Return the shared pointer.

Definition at line 32 of file object_base.cpp.

bool VOM::object_ref::operator< ( const object_ref other) const

less than operator

Definition at line 26 of file object_base.cpp.

bool VOM::object_ref::stale ( ) const

Query if the object is stale.

Definition at line 50 of file object_base.cpp.


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