Opm::ReservoirCoupling::Proxy< Scalar > Class Template Reference

Thin proxy for reservoir coupling master/slave pointers. More...

#include <RescoupProxy.hpp>

Inheritance diagram for Opm::ReservoirCoupling::Proxy< Scalar >:
Inheritance graph

Public Member Functions

 Proxy ()=default
 
 Proxy (const Proxy &)=default
 
Proxyoperator= (const Proxy &)=default
 
 Proxy (Proxy &&) noexcept=default
 
Proxyoperator= (Proxy &&) noexcept=default
 
bool isEnabled () const noexcept
 
bool isMaster () const noexcept
 
bool isSlave () const noexcept
 
void setMaster (ReservoirCouplingMaster< Scalar > *)
 
void setSlave (ReservoirCouplingSlave< Scalar > *)
 
ReservoirCouplingMaster< Scalar > * masterPtr () noexcept
 
const ReservoirCouplingMaster< Scalar > * masterPtr () const noexcept
 
ReservoirCouplingSlave< Scalar > * slavePtr () noexcept
 
const ReservoirCouplingSlave< Scalar > * slavePtr () const noexcept
 
ReservoirCouplingMaster< Scalar > & master ()
 
const ReservoirCouplingMaster< Scalar > & master () const
 
ReservoirCouplingSlave< Scalar > & slave ()
 
const ReservoirCouplingSlave< Scalar > & slave () const
 

Detailed Description

template<class Scalar>
class Opm::ReservoirCoupling::Proxy< Scalar >

Thin proxy for reservoir coupling master/slave pointers.

This class encapsulates pointers to ReservoirCouplingMaster and ReservoirCouplingSlave, providing mode queries that work regardless of MPI availability. This eliminates the need for #ifdef RESERVOIR_COUPLING_ENABLED guards in consumer code.

The proxy does not own the master/slave objects - they are owned by SimulatorFullyImplicitBlackoil. Pointers are set after construction via setMaster()/setSlave().

Master and slave modes are mutually exclusive - setting one clears the other.

Constructor & Destructor Documentation

◆ Proxy() [1/3]

template<class Scalar >
Opm::ReservoirCoupling::Proxy< Scalar >::Proxy ( )
default

◆ Proxy() [2/3]

template<class Scalar >
Opm::ReservoirCoupling::Proxy< Scalar >::Proxy ( const Proxy< Scalar > &  )
default

◆ Proxy() [3/3]

template<class Scalar >
Opm::ReservoirCoupling::Proxy< Scalar >::Proxy ( Proxy< Scalar > &&  )
defaultnoexcept

Member Function Documentation

◆ isEnabled()

template<class Scalar >
bool Opm::ReservoirCoupling::Proxy< Scalar >::isEnabled ( ) const
inlinenoexcept

◆ isMaster()

template<class Scalar >
bool Opm::ReservoirCoupling::Proxy< Scalar >::isMaster ( ) const
inlinenoexcept

◆ isSlave()

template<class Scalar >
bool Opm::ReservoirCoupling::Proxy< Scalar >::isSlave ( ) const
inlinenoexcept

◆ master() [1/2]

template<class Scalar >
ReservoirCouplingMaster< Scalar > & Opm::ReservoirCoupling::Proxy< Scalar >::master ( )
inline

◆ master() [2/2]

template<class Scalar >
const ReservoirCouplingMaster< Scalar > & Opm::ReservoirCoupling::Proxy< Scalar >::master ( ) const
inline

◆ masterPtr() [1/2]

template<class Scalar >
const ReservoirCouplingMaster< Scalar > * Opm::ReservoirCoupling::Proxy< Scalar >::masterPtr ( ) const
inlinenoexcept

◆ masterPtr() [2/2]

template<class Scalar >
ReservoirCouplingMaster< Scalar > * Opm::ReservoirCoupling::Proxy< Scalar >::masterPtr ( )
inlinenoexcept

◆ operator=() [1/2]

template<class Scalar >
Proxy & Opm::ReservoirCoupling::Proxy< Scalar >::operator= ( const Proxy< Scalar > &  )
default

◆ operator=() [2/2]

template<class Scalar >
Proxy & Opm::ReservoirCoupling::Proxy< Scalar >::operator= ( Proxy< Scalar > &&  )
defaultnoexcept

◆ setMaster()

template<class Scalar >
void Opm::ReservoirCoupling::Proxy< Scalar >::setMaster ( ReservoirCouplingMaster< Scalar > *  )
inline

◆ setSlave()

template<class Scalar >
void Opm::ReservoirCoupling::Proxy< Scalar >::setSlave ( ReservoirCouplingSlave< Scalar > *  )
inline

◆ slave() [1/2]

template<class Scalar >
ReservoirCouplingSlave< Scalar > & Opm::ReservoirCoupling::Proxy< Scalar >::slave ( )
inline

◆ slave() [2/2]

template<class Scalar >
const ReservoirCouplingSlave< Scalar > & Opm::ReservoirCoupling::Proxy< Scalar >::slave ( ) const
inline

◆ slavePtr() [1/2]

template<class Scalar >
const ReservoirCouplingSlave< Scalar > * Opm::ReservoirCoupling::Proxy< Scalar >::slavePtr ( ) const
inlinenoexcept

◆ slavePtr() [2/2]

template<class Scalar >
ReservoirCouplingSlave< Scalar > * Opm::ReservoirCoupling::Proxy< Scalar >::slavePtr ( )
inlinenoexcept

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