PcapPlusPlus
pcpp::PciAddress Class Reference

#include <DpdkDevice.h>

Public Member Functions

 PciAddress ()
 
 PciAddress (uint16_t domain, uint8_t bus, uint8_t devid, uint8_t function)
 
std::string toString ()
 
bool operator== (const PciAddress &other) const
 

Public Attributes

uint16_t domain
 
uint8_t bus
 
uint8_t devid
 
uint8_t function
 

Detailed Description

A class representing a PCI address

Constructor & Destructor Documentation

pcpp::PciAddress::PciAddress ( )
inline

Default c'tor that initializes all PCI address fields to 0 (until set otherwise, address will look like: 0000:00:00.0)

pcpp::PciAddress::PciAddress ( uint16_t  domain,
uint8_t  bus,
uint8_t  devid,
uint8_t  function 
)
inline

A c'tor that initializes all PCI address fields

Parameters
[in]domainDevice domain
[in]busDevice bus id
[in]devidDevice ID
[in]functionDevice function

Member Function Documentation

bool pcpp::PciAddress::operator== ( const PciAddress other) const
inline

Comparison operator overload. Two PCI addresses are equal if all of their address parts (domain, bus, devid, function) are equal

std::string pcpp::PciAddress::toString ( )
inline
Returns
The string format of the PCI address (xxxx:xx:xx.x)

Member Data Documentation

uint8_t pcpp::PciAddress::bus

Device bus id

uint8_t pcpp::PciAddress::devid

Device ID

uint16_t pcpp::PciAddress::domain

Device domain

uint8_t pcpp::PciAddress::function

Device function