Ice 3.8
C++ API Reference
Loading...
Searching...
No Matches
Ice::CommunicatorHolder Class Reference

A helper class that uses Resource Acquisition Is Initialization (RAII) to hold a communicator instance, and automatically destroy this instance when the holder goes out of scope. More...

#include <Ice/Ice.h>

Public Member Functions

 CommunicatorHolder ()=default
 Default constructor.
 CommunicatorHolder (CommunicatorHolder &&other)=default
 Move constructor.
 CommunicatorHolder (CommunicatorPtr communicator) noexcept
 Constructs a CommunicatorHolder that adopts an existing communicator.
 CommunicatorHolder (const CommunicatorHolder &)=delete
template<class... T>
 CommunicatorHolder (T &&... args)
 Constructs a CommunicatorHolder for a new communicator created using an Ice::initialize overload.
const CommunicatorPtrcommunicator () const noexcept
 Gets the communicator.
 operator bool () const noexcept
 Determines whether this holder holds a communicator.
const CommunicatorPtroperator-> () const noexcept
 Gets the communicator.
CommunicatorHolderoperator= (CommunicatorHolder &&holder) noexcept
 Move assignment operator.
CommunicatorHolderoperator= (CommunicatorPtr communicator) noexcept
 Assignment operator.
CommunicatorHolderoperator= (const CommunicatorHolder &) noexcept=delete
CommunicatorPtr release () noexcept
 Gets the communicator and clears the reference held by the holder.

Detailed Description

A helper class that uses Resource Acquisition Is Initialization (RAII) to hold a communicator instance, and automatically destroy this instance when the holder goes out of scope.

Definition at line 356 of file Communicator.h.


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