Image Component Library (ICL)
Static Public Member Functions | Static Private Member Functions | Friends | List of all members
icl::io::SharedMemorySegmentRegister Class Reference

This is used to register all created SharedMemorySegments. More...

#include <SharedMemorySegment.h>

Static Public Member Functions

static std::set< std::string > getSegmentSet ()
 Returns a set of the currently registered SharedMemorySegments. More...
 
static void freeSegment (std::string name)
 Linux only. When a SharedMemory was not released correctly this can help. More...
 
static void freeAllSegments ()
 calls freeSegment() on all registered SharedMemorySegments More...
 
static void resetBus ()
 Linux only. Releases all SharedMemorySegments and SystemSemaphores. More...
 

Static Private Member Functions

static void addSegment (std::string name)
 Adds a segment name to the register. More...
 
static void removeSegment (std::string name)
 Removes a segment name to the register. More...
 

Friends

struct SharedMemorySegment::Impl
 

Detailed Description

This is used to register all created SharedMemorySegments.

Each SharedMemorySegment::Impl instance adds its segment name to the register on creation and removes it on destruction.

Member Function Documentation

◆ addSegment()

static void icl::io::SharedMemorySegmentRegister::addSegment ( std::string  name)
staticprivate

Adds a segment name to the register.

◆ freeAllSegments()

static void icl::io::SharedMemorySegmentRegister::freeAllSegments ( )
static

calls freeSegment() on all registered SharedMemorySegments

◆ freeSegment()

static void icl::io::SharedMemorySegmentRegister::freeSegment ( std::string  name)
static

Linux only. When a SharedMemory was not released correctly this can help.

Attaches and detatches the Segment identified by 'name'. When no other instances are connected. This will free the system memory segment.

◆ getSegmentSet()

static std::set<std::string> icl::io::SharedMemorySegmentRegister::getSegmentSet ( )
static

Returns a set of the currently registered SharedMemorySegments.

◆ removeSegment()

static void icl::io::SharedMemorySegmentRegister::removeSegment ( std::string  name)
staticprivate

Removes a segment name to the register.

◆ resetBus()

static void icl::io::SharedMemorySegmentRegister::resetBus ( )
static

Linux only. Releases all SharedMemorySegments and SystemSemaphores.

All SharedMemorySegments and SystemSemaphores starting with adress '0x51' will be freed by force. This is the last resource when something realy bad happened.

Friends And Related Function Documentation

◆ SharedMemorySegment::Impl

friend struct SharedMemorySegment::Impl
friend

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