lintel 0.2.0
Loading...
Searching...
No Matches
Public Member Functions | List of all members
lintel::SharedMemorySegmentInfo Class Reference

#include <SharedMemorySegmentInfo.h>

Public Member Functions

 SharedMemorySegmentInfo (std::shared_ptr< SharedMemorySegment > sharedMemorySegment, size_t currentSize, size_t freeSize, size_t amountNamedObjects, size_t amountUniqueObjects, bool sanity)
 
const std::shared_ptr< SharedMemorySegment > & getSharedMemorySegment () const
 
constexpr size_t getCurrentSize () const
 
constexpr size_t getFreeSize () const
 
constexpr size_t getAmountNamedObjects () const
 
constexpr size_t getAmountUniqueObjects () const
 
constexpr bool isSanity () const
 

Detailed Description

Provides information about a shared memory segment, including its current size, free space, and object counts.

Constructor & Destructor Documentation

◆ SharedMemorySegmentInfo()

lintel::SharedMemorySegmentInfo::SharedMemorySegmentInfo ( std::shared_ptr< SharedMemorySegment >  sharedMemorySegment,
size_t  currentSize,
size_t  freeSize,
size_t  amountNamedObjects,
size_t  amountUniqueObjects,
bool  sanity 
)

Constructor.

Parameters
sharedMemorySegmentthe underlying shared memory segment
currentSizecurrently used size in bytes
freeSizefree space in bytes
amountNamedObjectsnumber of named objects in the segment
amountUniqueObjectsnumber of unique (unnamed) objects
sanitywhether the segment passes sanity checks

Member Function Documentation

◆ getAmountNamedObjects()

constexpr size_t lintel::SharedMemorySegmentInfo::getAmountNamedObjects ( ) const
inlineconstexpr
Returns
number of named objects

◆ getAmountUniqueObjects()

constexpr size_t lintel::SharedMemorySegmentInfo::getAmountUniqueObjects ( ) const
inlineconstexpr
Returns
number of unique (unnamed) objects

◆ getCurrentSize()

constexpr size_t lintel::SharedMemorySegmentInfo::getCurrentSize ( ) const
inlineconstexpr
Returns
currently used size in bytes

◆ getFreeSize()

constexpr size_t lintel::SharedMemorySegmentInfo::getFreeSize ( ) const
inlineconstexpr
Returns
free space in bytes

◆ getSharedMemorySegment()

const std::shared_ptr< SharedMemorySegment > & lintel::SharedMemorySegmentInfo::getSharedMemorySegment ( ) const
Returns
the underlying shared memory segment

◆ isSanity()

constexpr bool lintel::SharedMemorySegmentInfo::isSanity ( ) const
inlineconstexpr
Returns
true if the segment passes sanity checks

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