bmv2
Designing your own switch target with bmv2
Public Member Functions | List of all members
bm::NamedP4Object Class Reference
Inheritance diagram for bm::NamedP4Object:
Inheritance graph
[legend]

Public Member Functions

const std::string & get_name () const
 Get the name of the P4 instance. More...
 
p4object_id_t get_id () const
 Get the compiler-provided id. More...
 
 NamedP4Object (const NamedP4Object &other)=delete
 Deleted copy constructor. More...
 
NamedP4Objectoperator= (const NamedP4Object &other)=delete
 Deleted copy assignment operator. More...
 
 NamedP4Object (NamedP4Object &&other)=default
 Default move constructor. More...
 
NamedP4Objectoperator= (NamedP4Object &&other)=default
 Default assignment operator. More...
 

Detailed Description

NamedP4Object is used as a base class for all the bmv2 classes with are used to represent named P4 objects (e.g. Parser for P4 parser objects). It just stores the name of the P4 instance and a compiler-provided id, which is different from the id of other objects of the same class.

Constructor & Destructor Documentation

◆ NamedP4Object() [1/2]

bm::NamedP4Object::NamedP4Object ( const NamedP4Object other)
delete

Deleted copy constructor.

◆ NamedP4Object() [2/2]

bm::NamedP4Object::NamedP4Object ( NamedP4Object &&  other)
default

Default move constructor.

Member Function Documentation

◆ get_id()

p4object_id_t bm::NamedP4Object::get_id ( ) const
inline

Get the compiler-provided id.

◆ get_name()

const std::string& bm::NamedP4Object::get_name ( ) const
inline

Get the name of the P4 instance.

◆ operator=() [1/2]

NamedP4Object& bm::NamedP4Object::operator= ( const NamedP4Object other)
delete

Deleted copy assignment operator.

◆ operator=() [2/2]

NamedP4Object& bm::NamedP4Object::operator= ( NamedP4Object &&  other)
default

Default assignment operator.


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