tmp< T > Class Template Reference

A class for managing temporary objects. More...

Inheritance diagram for tmp< T >:

Public Types

typedef T element_type
 Type of object being managed or referenced. More...
 
typedef Tpointer
 Pointer to type of object being managed or referenced. More...
 
typedef Foam::refCount refCount
 Reference counter class. More...
 

Public Member Functions

constexpr tmp () noexcept
 Construct with no managed pointer. More...
 
constexpr tmp (std::nullptr_t) noexcept
 Implicit construct from literal nullptr: no managed pointer. More...
 
 tmp (T *p)
 Construct, taking ownership of the pointer. More...
 
constexpr tmp (const T &obj) noexcept
 Implicit construct for a const reference to an object. More...
 
 tmp (tmp< T > &&rhs) noexcept
 Move construct, transferring ownership. More...
 
 tmp (const tmp< T > &&rhs) noexcept
 Move construct, transferring ownership. More...
 
 tmp (const tmp< T > &rhs)
 Copy construct, incrementing ref-count of managed pointer. More...
 
 tmp (const tmp< T > &rhs, bool reuse)
 Copy/move construct. Optionally reusing ref-counted pointer. More...
 
 tmp (const autoPtr< T > &)=delete
 No copy construct from autoPtr, also avoids implicit cast to object or pointer. More...
 
 tmp (const refPtr< T > &)=delete
 No copy construct from refPtr, also avoids implicit cast to object. More...
 
 tmp (autoPtr< T > &&rhs) noexcept
 Move construct from autoPtr, transferring ownership. More...
 
 ~tmp () noexcept
 Destructor: deletes managed pointer when the ref-count is 0. More...
 
bool good () const noexcept
 True if pointer/reference is non-null. More...
 
bool is_const () const noexcept
 If the stored/referenced content is const. More...
 
bool is_pointer () const noexcept
 True if this is a managed pointer (not a reference) More...
 
bool is_reference () const noexcept
 True if this is a reference (not a pointer) More...
 
bool movable () const noexcept
 True if this is a non-null managed pointer with a unique ref-count. More...
 
Tget () noexcept
 Return pointer without nullptr checking. More...
 
const Tget () const noexcept
 Return const pointer without nullptr checking. More...
 
const Tcref () const
 Return const reference to the object or to the contents of a (non-null) managed pointer. More...
 
Tref () const
 Return non-const reference to the contents of a non-null managed pointer. More...
 
TconstCast () const
 Return non-const reference to the object or to the contents of a (non-null) managed pointer, with an additional const_cast. More...
 
Tptr () const
 Return managed pointer for reuse, or clone() the object reference. More...
 
void clear () const noexcept
 If object pointer points to valid object: delete object and set pointer to nullptr. More...
 
void protect (bool on) noexcept
 Use specified protection against moving for the managed pointer. No-op for references. More...
 
void reset (tmp< T > &&other) noexcept
 Clear existing and transfer ownership. More...
 
void reset (T *p=nullptr) noexcept
 Delete managed temporary object and set to new given pointer. More...
 
void reset (const autoPtr< T > &)=delete
 Avoid inadvertent casting (to object or pointer) More...
 
void reset (const refPtr< T > &)=delete
 Avoid inadvertent casting (to object) More...
 
template<class... Args>
Templace (Args &&... args)
 Reset with emplace construction. Return reference to the new content. More...
 
void cref (const tmp< T > &other) noexcept
 Clear existing and set (const) reference from other. More...
 
void cref (const T &obj) noexcept
 Clear existing and set (const) reference. More...
 
void cref (const T *p) noexcept
 Clear existing and set (const) reference to pointer content. More...
 
void cref (const autoPtr< T > &)=delete
 Avoid inadvertent casting (to object or pointer) More...
 
void cref (const refPtr< T > &)=delete
 Avoid inadvertent casting (to object) More...
 
void ref (T &obj) noexcept
 Clear existing and set to (non-const) reference. More...
 
void ref (T *p) noexcept
 Clear existing and set (non-const) reference to pointer content. More...
 
void ref (const autoPtr< T > &)=delete
 Avoid inadvertent casting (to object or pointer) More...
 
void ref (const refPtr< T > &)=delete
 Avoid inadvertent casting (to object) More...
 
void swap (tmp< T > &other) noexcept
 Swaps the managed object with other. More...
 
const Toperator-> () const
 Dereferences (const) pointer to the managed object. More...
 
Toperator-> ()
 Dereferences (non-const) pointer to the managed object. More...
 
const Toperator() () const
 Return const reference to the object - same as cref() method. More...
 
 operator bool () const noexcept
 True if pointer/reference is non-null. Same as good() More...
 
 operator const T & () const
 Cast to underlying data type, using the cref() method. More...
 
void operator= (const tmp< T > &other)
 Transfer ownership of the managed pointer. More...
 
void operator= (tmp< T > &&other) noexcept
 Clear existing and transfer ownership. More...
 
void operator= (T *p)
 Take ownership of the pointer. More...
 
void operator= (std::nullptr_t) noexcept
 Reset via assignment from literal nullptr. More...
 
bool valid () const noexcept
 Identical to good(), or bool operator. More...
 
bool isTmp () const noexcept
 Identical to is_pointer(). Prefer is_pointer() or movable(). More...
 
bool empty () const noexcept
 Deprecated(2020-07) True if a null managed pointer. More...
 

Static Public Member Functions

template<class... Args>
static tmp< TNew (Args &&... args)
 Construct tmp with forwarding arguments. More...
 
template<class U , class... Args>
static tmp< TNewFrom (Args &&... args)
 Construct tmp from derived type with forwarding arguments. More...
 
static word typeName ()
 The type-name, constructed from type-name of T. More...
 

Detailed Description

template<class T>
class Foam::tmp< T >

A class for managing temporary objects.

This is a combination of std::shared_ptr (with intrusive ref-counting) and a shared_ptr without ref-counting and null deleter. This allows the tmp to double as a pointer management and an indirect pointer to externally allocated objects. In contrast to std::shared_ptr, only a limited number of tmp items will ever share a pointer.

Source files
See also
Foam::autoPtr Foam::refPtr Foam::refCount

Definition at line 50 of file HashPtrTable.H.

Member Typedef Documentation

◆ element_type

typedef T element_type

Type of object being managed or referenced.

Definition at line 107 of file tmp.H.

◆ pointer

typedef T* pointer

Pointer to type of object being managed or referenced.

Definition at line 112 of file tmp.H.

◆ refCount

Reference counter class.

Definition at line 118 of file tmp.H.

Constructor & Destructor Documentation

◆ tmp() [1/11]

constexpr tmp ( )
inlinenoexcept

Construct with no managed pointer.

Definition at line 54 of file tmpI.H.

◆ tmp() [2/11]

constexpr tmp ( std::nullptr_t  )
inlinenoexcept

Implicit construct from literal nullptr: no managed pointer.

Definition at line 62 of file tmpI.H.

◆ tmp() [3/11]

tmp ( T p)
inlineexplicit

Construct, taking ownership of the pointer.

Definition at line 70 of file tmpI.H.

◆ tmp() [4/11]

constexpr tmp ( const T obj)
inlinenoexcept

Implicit construct for a const reference to an object.

Definition at line 87 of file tmpI.H.

◆ tmp() [5/11]

tmp ( tmp< T > &&  rhs)
inlinenoexcept

Move construct, transferring ownership.

Does not affect ref-count

Definition at line 95 of file tmpI.H.

◆ tmp() [6/11]

tmp ( const tmp< T > &&  rhs)
inlinenoexcept

Move construct, transferring ownership.

Does not affect ref-count

Note
Non-standard definition - should be non-const

Definition at line 106 of file tmpI.H.

◆ tmp() [7/11]

tmp ( const tmp< T > &  rhs)
inline

Copy construct, incrementing ref-count of managed pointer.

Note
Non-standard definition - should be non-const

Definition at line 117 of file tmpI.H.

◆ tmp() [8/11]

tmp ( const tmp< T > &  rhs,
bool  reuse 
)
inline

Copy/move construct. Optionally reusing ref-counted pointer.

Definition at line 141 of file tmpI.H.

◆ tmp() [9/11]

tmp ( const autoPtr< T > &  )
delete

No copy construct from autoPtr, also avoids implicit cast to object or pointer.

◆ tmp() [10/11]

tmp ( const refPtr< T > &  )
delete

No copy construct from refPtr, also avoids implicit cast to object.

◆ tmp() [11/11]

tmp ( autoPtr< T > &&  rhs)
inlineexplicitnoexcept

Move construct from autoPtr, transferring ownership.

Definition at line 173 of file tmpI.H.

◆ ~tmp()

~tmp ( )
inlinenoexcept

Destructor: deletes managed pointer when the ref-count is 0.

Definition at line 182 of file tmpI.H.

Member Function Documentation

◆ New()

static tmp<T> New ( Args &&...  args)
inlinestatic

Construct tmp with forwarding arguments.

Parameters
argslist of arguments with which an instance of T will be constructed.
Note
Similar to std::make_shared, but the overload for array types is not disabled.

Definition at line 206 of file tmp.H.

Referenced by solidAbsorption::a(), nullSpace::activeConstraints(), scene::addColourToMesh(), viscousDissipation::addSup(), adjointLaminar::adjointMeanFlowSource(), boundaryAdjointContribution::adjointTMVariable1Source(), boundaryAdjointContribution::adjointTMVariable2Source(), acousticWaveTransmissiveFvPatchField< Type >::advectionSpeed(), GAMGInterface::agglomerateCoeffs(), nullSpace::ATv(), variablesSet::autoCreateMeshMovementField(), nullSpace::Av(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::beta(), adjointkOmegaSST::beta(), blendingFactor::blendingFactor(), alphatPhaseChangeJayatillekeWallFunctionFvPatchScalarField::calcAlphat(), nutLowReWallFunctionFvPatchScalarField::calcNut(), nutkWallFunctionFvPatchScalarField::calcNut(), nutUWallFunctionFvPatchScalarField::calcNut(), nutkRoughWallFunctionFvPatchScalarField::calcNut(), atmNutUWallFunctionFvPatchScalarField::calcNut(), atmNutkWallFunctionFvPatchScalarField::calcNut(), atmNutWallFunctionFvPatchScalarField::calcNut(), MassTransferPhaseSystem< BasePhaseSystem >::calculateL(), nutUTabulatedWallFunctionFvPatchScalarField::calcUPlus(), nutkFilmWallFunctionFvPatchScalarField::calcUTau(), nutUBlendedWallFunctionFvPatchScalarField::calcUTau(), nutUSpaldingWallFunctionFvPatchScalarField::calcUTau(), nutUWallFunctionFvPatchScalarField::calcYPlus(), deltaBoundary::cellCenters_d(), treeDataPoint::centres(), treeDataCell::centres(), treeDataFace::centres(), treeDataEdge::centres(), designVariablesUpdate::computeDirection(), kEpsilon::computeG(), kOmegaSST::computeG(), adjointEikonalSolver::computeYPhi(), nullSpace::constraintRelatedUpdate(), searchablePlane::coordinates(), searchableBox::coordinates(), searchableDisk::coordinates(), searchablePlate::coordinates(), searchableCylinder::coordinates(), searchableSurfaceCollection::coordinates(), searchableCone::coordinates(), triSurfaceMesh::coordinates(), searchableSphere::coordinates(), NURBS3DVolume::coordinates(), contactAngleForce::correct(), twoPhaseMixtureEThermo::Cp(), ReynoldsAnalogy::Cp(), twoPhaseMixtureThermo::Cp(), multiphaseMixtureThermo::Cp(), multiphaseInterSystem::Cp(), Foam::fv::createField(), cellCellStencil::createField(), displacementMeshMoverMotionSolver::curPoints(), solidBodyMotionSolver::curPoints(), multiSolidBodyMotionSolver::curPoints(), triSurfaceTools::curvatures(), filmTurbulenceModel::Cw(), faMatrix< Type >::D(), fvMatrix< Type >::D(), volumetricBSplinesDesignVariables::dCdb(), MRFZoneList::DDt(), cyclicFaPatch::delta(), cyclicACMIFvPatch::delta(), cyclicAMIFvPatch::delta(), basicFvGeometryScheme::deltaCoeffs(), linearInterpolation::derivative(), smoothHeaviside::derivative(), sigmoidalHeaviside::derivative(), DESModelRegions::DESModelRegions(), RASModelVariables::devReff(), adjointSpalartAllmaras::devReff(), adjointkOmegaSST::devReff(), InterfaceCompositionModel< Thermo, OtherThermo >::Dfrom(), solarCalculator::diffuseSolarRad(), adjointRASModel::diffusionCoeffVar1(), adjointRASModel::diffusionCoeffVar2(), adjointLaminar::distanceSensitivities(), adjointSpalartAllmaras::distanceSensitivities(), adjointkOmegaSST::distanceSensitivities(), momentumError::divDevRhoReff(), boundaryAdjointContribution::dJdGradU(), boundaryAdjointContribution::dJdnut(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::DkEff(), kL< BasicTurbulenceModel >::DkEff(), MassTransferPhaseSystem< BasePhaseSystem >::dmdt(), Bezier::dndbBasedSensitivities(), adjointSpalartAllmaras::DnuTildaEff(), SpalartAllmarasBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::DnuTildaEff(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::DomegaEff(), kEpsilonPhitF< BasicTurbulenceModel >::DphitEff(), multiphaseMangrovesSource::dragCoeff(), surfactantProperties::dSigma(), InterfaceCompositionModel< Thermo, OtherThermo >::Dto(), Bezier::dxdbFace(), adjointRotatingWallVelocityFvPatchVectorField::dxdbMult(), volumetricBSplinesDesignVariables::dxdbVol(), shapeDesignVariables::dxdbVol(), solidAbsorption::e(), faMesh::edgeLengthCorrection(), faPatch::edgeNormals(), cloudAbsorptionEmission::eDisp(), sigma< BasicTurbulenceModel >::epsilon(), SpalartAllmarasBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::epsilon(), age::execute(), energyTransport::execute(), boundedBackwardFaDdtScheme::facDdt(), boundBox::faceCentres(), mappedPatchBase::facePoints(), DESModel< BasicTurbulenceModel >::fd(), parseDriver::field_cellCentre(), parseDriver::field_rand(), NURBS3DSurface::findClosestSurfacePoint(), adjointLaminar::FISensitivityTerm(), fft::forwardTransform(), interfaceTrackingFvMesh::freeSurfacePressureJump(), interfaceTrackingFvMesh::freeSurfaceSnGradU(), interfaceTrackingFvMesh::freeSurfaceSnGradUn(), noiseFFT::frequencies(), SpalartAllmarasBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::ft2(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::gamma(), adjointkOmegaSST::gamma(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::GbyNu0(), multiphaseInterSystem::generatePhi(), Foam::getBoundedColours(), Foam::getField(), cancelATC::getFISensitivityTerm(), ATCstandard::getFISensitivityTerm(), adjointSolver::getObjectiveSensitivities(), InterfaceCompositionModel< Thermo, OtherThermo >::getSpecieMassFraction(), blockMesh::globalPosition(), adjointEikonalSolver::gradEikonal(), lduMatrix::H1(), faMesh::haloFaceCentres(), faMesh::haloFaceNormals(), MassTransferPhaseSystem< BasePhaseSystem >::heatTransfer(), boundBox::hexCorners(), multiphaseMangrovesSource::inertiaCoeff(), rotorDiskSource::inflowVelocity(), cyclicFvPatch::interfaceInternalField(), processorFvPatch::interfaceInternalField(), cyclicFaPatch::interfaceInternalField(), cyclicAMIFvPatch::interfaceInternalField(), cyclicACMIFvPatch::interfaceInternalField(), processorFaPatch::interfaceInternalField(), AssemblyFvPatch< CyclicType >::internalFieldTransfer(), cyclicFaPatch::internalFieldTransfer(), leastSquaresEdgeInterpolation< Type >::interpolate(), Foam::inv(), coordinateSystem::invTransformPointImpl(), sigma< BasicTurbulenceModel >::k(), SpalartAllmarasBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::k(), multiphaseInterSystem::kappaEff(), interfaceHeatResistance< Thermo, OtherThermo >::Kexp(), diffusionGasEvaporation< Thermo, OtherThermo >::Kexp(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::kSource(), kL< BasicTurbulenceModel >::kSource(), interfaceHeatResistance< Thermo, OtherThermo >::KSu(), InterfaceCompositionModel< Thermo, OtherThermo >::L(), SpalartAllmarasDES< BasicTurbulenceModel >::LESRegion(), kOmegaSSTDES< BasicTurbulenceModel >::LESRegion(), upwind< Type >::limiter(), cylindrical::localToGlobal(), meshRefinement::makeDisplacementField(), speciesSorptionFvPatchScalarField::mass(), noiseModel::meanPf(), incompressibleTwoPhaseMixture::mu(), incompressibleTwoPhaseMixture::muf(), laminar::mut(), InterfaceCompositionModel< Thermo, OtherThermo >::MwMixture(), multiphaseInterSystem::nearInterface(), processorFaPatch::neighbEdgeNormals(), faPatch::ngbPolyPatchFaceNormals(), faPatch::ngbPolyPatchPointNormals(), basicFvGeometryScheme::nonOrthCorrectionVectors(), basicFvGeometryScheme::nonOrthDeltaCoeffs(), limitTurbulenceViscosity::nu(), adjointTurbulenceModel::nuEff(), incompressibleTwoPhaseMixture::nuf(), Stokes< BasicTurbulenceModel >::nut(), generalizedNewtonian< BasicMomentumTransportModel >::nut(), RASModelVariables::nut(), adjointRASModel::nutJacobianTMVar1(), adjointRASModel::nutJacobianTMVar2(), SpalartAllmaras::nutJacobianVar1(), RASModelVariables::nutJacobianVar1(), RASModelVariables::nutJacobianVar2(), RASModelVariables::nutPatchField(), noiseModel::octaves(), SpalartAllmarasBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::omega(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::omegaSource(), NURBS3DVolume::patchDxDb(), NURBS3DVolume::patchDxDbFace(), enthalpySorptionFvPatchScalarField::patchSource(), speciesSorptionFvPatchScalarField::patchSource(), noiseFFT::Pf(), noiseModel::Pf(), semiPermeableBaffleMassFractionFvPatchScalarField::phiY(), searchablePlate::points(), searchableCylinder::points(), searchableSurfaceCollection::points(), treeBoundBox::points(), searchableCone::points(), lumpedPointMovement::pointsDisplacement(), lumpedPointMovement::pointsPosition(), projectCurveEdge::position(), projectEdge::position(), blockEdge::position(), filmTurbulenceModel::primaryRegionFriction(), noiseModel::PSDf(), SpalartAllmarasDES< BasicTurbulenceModel >::psi(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::Qsas(), dummy::R(), adjointSpalartAllmaras::r(), lumpedPointMovement::readDict(), reader::readField(), fft::realTransform1D(), fft::reverseTransform(), filmTurbulenceModel::rho(), ReynoldsAnalogy::rho(), forces::rho(), twoPhaseMixtureEThermo::rhoEoS(), twoPhaseMixtureThermo::rhoEoS(), multiphaseMixtureThermo::rhoEoS(), coordinateSystem::rotationsImpl(), noRadiation::Rp(), opaqueSolid::Rp(), viewFactor::Rp(), solarLoad::Rp(), noRadiation::Ru(), opaqueSolid::Ru(), Foam::safeLog10(), mappedPatchBase::samplePoints(), noFilm::Sh(), ThermoCloud< Foam::DSMCCloud >::Sh(), kinematicSingleLayer::Sh(), noRadiation::Shs(), constantSurfaceTensionCoefficient::sigma(), constant::sigma(), temperatureDependent::sigma(), electrostaticDepositionFvPatchScalarField::sigma(), timeVaryingMassSorptionFvPatchScalarField::source(), noFilm::Srho(), kinematicSingleLayer::Srho(), stabilityBlendingFactor::stabilityBlendingFactor(), Foam::sumNeighbours(), multiphaseInterSystem::surfaceTensionForce(), interfaceTrackingFvMesh::surfaceTensionGrad(), dynamicContactAngleForce::theta(), targetCoeffTrim::thetag(), RASModelVariables::TMVar1(), RASModelVariables::TMVar2(), boundaryAdjointContribution::TMVariable1(), boundaryAdjointContribution::TMVariable1Diffusion(), boundaryAdjointContribution::TMVariable2(), boundaryAdjointContribution::TMVariable2Diffusion(), adjointLaminar::topologySensitivities(), cyclicFaPatch::transfer(), Foam::transformFieldMask< tensor >(), coordinateSystem::transformPointImpl(), multiphaseInterSystem::U(), noiseModel::uniformFrequencies(), faMesh::unitLe(), fvMesh::unitSf(), resolutionIndexModel::V(), triSurfaceTools::vertexNormals(), triSurfaceTools::vertexTriads(), blockMesh::vertices(), MassTransferPhaseSystem< BasePhaseSystem >::volTransfer(), waveModel::waterLevel(), surfaceFieldValue::weightingFactor(), basicFvGeometryScheme::weights(), electricPotential::write(), rotorDiskSource::writeField(), TableBase< Type >::x(), general::x(), general::y(), nutkWallFunctionFvPatchScalarField::yPlus(), alphatPhaseChangeJayatillekeWallFunctionFvPatchScalarField::yPlusTherm(), and adjointkOmegaSST::zeroFirstCell().

◆ NewFrom()

static tmp<T> NewFrom ( Args &&...  args)
inlinestatic

Construct tmp from derived type with forwarding arguments.

Parameters
argslist of arguments with which an instance of U will be constructed.
Note
Similar to New but for derived types. Future check std::enable_if + std::is_convertible ?

Definition at line 221 of file tmp.H.

◆ typeName()

Foam::word typeName ( )
inlinestatic

The type-name, constructed from type-name of T.

Definition at line 28 of file tmpI.H.

◆ good()

bool good ( ) const
inlinenoexcept

True if pointer/reference is non-null.

Definition at line 240 of file tmp.H.

Referenced by multiphaseSystem::dragCoeff().

Here is the caller graph for this function:

◆ is_const()

bool is_const ( ) const
inlinenoexcept

If the stored/referenced content is const.

Definition at line 191 of file tmpI.H.

Referenced by refPtr< Foam::mapDistributePolyMesh >::reset().

Here is the caller graph for this function:

◆ is_pointer()

bool is_pointer ( ) const
inlinenoexcept

True if this is a managed pointer (not a reference)

Definition at line 198 of file tmpI.H.

Referenced by tmp< Foam::surfaceInterpolationScheme< GType > >::isTmp(), tmp< Foam::surfaceInterpolationScheme< GType > >::operator=(), refPtr< Foam::mapDistributePolyMesh >::reset(), and regIOobject::store().

Here is the caller graph for this function:

◆ is_reference()

bool is_reference ( ) const
inlinenoexcept

◆ movable()

bool movable ( ) const
inlinenoexcept

True if this is a non-null managed pointer with a unique ref-count.

Definition at line 214 of file tmpI.H.

Referenced by DispersionRASModel< CloudType >::cacheFields(), and BrownianMotionForce< CloudType >::cacheFields().

Here is the caller graph for this function:

◆ get() [1/2]

T* get ( )
inlinenoexcept

Return pointer without nullptr checking.

Definition at line 268 of file tmp.H.

Referenced by refPtr< Foam::mapDistributePolyMesh >::reset(), and regIOobject::store().

Here is the caller graph for this function:

◆ get() [2/2]

const T* get ( ) const
inlinenoexcept

Return const pointer without nullptr checking.

Definition at line 273 of file tmp.H.

◆ cref() [1/6]

◆ ref() [1/5]

T & ref ( ) const
inline

Return non-const reference to the contents of a non-null managed pointer.

Fatal for a null managed pointer or if the object is const.

Definition at line 235 of file tmpI.H.

Referenced by MRFZoneList::absolute(), adjointNull::accumulateGradDxDbMultiplier(), incompressibleAdjointSolver::accumulateGradDxDbMultiplier(), multiBandZoneAbsorptionEmission::aCont(), greyMeanAbsorptionEmission::aCont(), wideBandAbsorptionEmission::aCont(), jouleHeatingSource::addSup(), SemiImplicitSource< Type >::addSup(), phaseChange::addToDriftRate(), cloudAbsorptionEmission::aDisp(), adjointkOmegaSST::adjointMeanFlowSource(), coordSetWriter::adjustFieldTemplate(), surfaceWriter::adjustFieldTemplate(), surfaceWriter::adjustSurface(), adjointSolverManager::aggregateSensitivities(), liquidFilmBase::alpha(), KinematicCloud< Cloud< basicKinematicCollidingParcel > >::alpha(), multiphaseInterSystem::alphaEff(), multiphaseInterSystem::alphahe(), MassTransferPhaseSystem< BasePhaseSystem >::alphaTransfer(), ThermoCloud< Foam::DSMCCloud >::ap(), polyPatch::areaFraction(), shapeDesignVariables::assembleSensitivities(), Foam::atan2(), Foam::fac::average(), Foam::fvc::average(), averageNeighbourFvGeometryScheme::averageCentres(), averageNeighbourFvGeometryScheme::averageNeighbourCentres(), subtract::calcFieldType(), add::calcFieldType(), faceLimitedGrad< Type >::calcGrad(), faceMDLimitedGrad< Type >::calcGrad(), cellMDLimitedGrad< Type >::calcGrad(), curvatureSeparation::calcInvR1(), nutUSpaldingWallFunctionFvPatchScalarField::calcNut(), phaseSystem::calcPhi(), StandardChemistryModel< CompType, ThermoType >::calculateRR(), treeDataEdge::centres(), Zuber::CHF(), Tatsumoto::CHFSubCool(), HuaXu::CHFSubCool(), Foam::cmptMag(), NURBS3DVolume::computeNewBoundaryPoints(), NURBS3DVolume::computeNewPoints(), NURBS3DVolume::computeParametricCoordinates(), nullSpace::computeResiduals(), ISQP::computeResiduals(), ISQP::computeRHSForDeltaX(), Foam::constrainHbyA(), forceList::correct(), thermocapillaryForce::correct(), contactAngleForce::correct(), DeardorffDiffStress< BasicTurbulenceModel >::correct(), Maxwell< BasicTurbulenceModel >::correct(), ShihQuadraticKE::correct(), LamBremhorstKE::correct(), LienLeschziner::correct(), kOmega< BasicTurbulenceModel >::correct(), LienCubicKE::correct(), realizableKE< BasicTurbulenceModel >::correct(), SSG< BasicTurbulenceModel >::correct(), kEpsilon< EddyDiffusivity< compressible::turbulenceModel > >::correct(), RNGkEpsilon< BasicTurbulenceModel >::correct(), LaunderSharmaKE< BasicTurbulenceModel >::correct(), LRR< BasicTurbulenceModel >::correct(), qZeta::correct(), kEpsilonLopesdaCosta< BasicTurbulenceModel >::correct(), SpalartAllmarasBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::correct(), EBRSM< BasicTurbulenceModel >::correct(), mixtureKEpsilon< BasicTurbulenceModel >::correct(), kkLOmega::correct(), kEpsilonPhitF< BasicTurbulenceModel >::correct(), adjointSpalartAllmaras::correct(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::correct(), kL< BasicTurbulenceModel >::correct(), adjointkOmegaSST::correct(), correctedLnGrad< Type >::correction(), fourthLnGrad< Type >::correction(), cubic< Type >::correction(), pointLinear< Type >::correction(), CentredFitSnGradScheme< Type, Polynomial, Stencil >::correction(), correctedSnGrad< Type >::correction(), faceCorrectedSnGrad< Type >::correction(), deferredCorrection< Type >::correction(), relaxedSnGrad< Type >::correction(), outletStabilised< Type >::correction(), MassTransferPhaseSystem< BasePhaseSystem >::correctMassSources(), kOmegaSSTLM< BasicTurbulenceModel >::correctReThetatGammaInt(), constantFilmThermo::Cp(), multiphaseInterSystem::Cp(), heThermo< BasicSolidThermo, MixtureType >::CpByCpv(), multiphaseInterSystem::CpByCpv(), heThermo< BasicSolidThermo, MixtureType >::Cpv(), multiphaseInterSystem::Cpv(), Foam::fvc::curl(), volumetricBSplinesMotionSolver::curPoints(), velocityComponentLaplacianFvMotionSolver::curPoints(), displacementComponentLaplacianFvMotionSolver::curPoints(), displacementSBRStressFvMotionSolver::curPoints(), displacementInterpolationMotionSolver::curPoints(), sixDoFRigidBodyMotionSolver::curPoints(), rigidBodyMeshMotion::curPoints(), multiphaseInterSystem::Cv(), multiphaseSystem::Cvm(), fvMatrix< Type >::DD(), MomentumTransferPhaseSystem< BasePhaseSystem >::ddtCorrByAs(), fvFieldDecomposer::decomposeField(), cyclicFvPatch::delta(), fvMesh::delta(), blackBodyEmission::deltaLambdaT(), smoothHeaviside::derivative(), sinhInterpolation::derivative(), sigmoidalHeaviside::derivative(), SIMPInterpolation::derivative(), invBP::derivative(), expInterpolation::derivative(), BorrvallPeterssonInterpolation::derivative(), tanhInterpolation::derivative(), nonlinearEddyViscosity< incompressible::RASModel >::devRhoReff(), ISQP::diagPreconditioner(), adjointSpalartAllmaras::diffusionCoeffVar1(), adjointSpalartAllmaras::distanceSensitivities(), Foam::fac::div(), NURBS3DVolume::dndbBasedSensitivities(), adjointSpalartAllmaras::dr_dDelta(), adjointkOmegaSST::dR_dF1(), adjointkOmegaSST::dR_dnut(), adjointSpalartAllmaras::dr_dNuTilda(), adjointSpalartAllmaras::dr_dStilda(), SpalartAllmarasDES< BasicTurbulenceModel >::dTilda(), blackBodyEmission::EbDeltaLambdaT(), multiBandZoneAbsorptionEmission::eCont(), greyMeanAbsorptionEmission::ECont(), wideBandAbsorptionEmission::ECont(), Foam::fac::edgeIntegrate(), Foam::fac::edgeSum(), ThermoCloud< Foam::DSMCCloud >::Ep(), edgeInterpolationScheme< scalar >::euclidianInterpolate(), PopeIndex::execute(), scalarTransport::execute(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::F23(), EulerFaD2dt2Scheme< Type >::facD2dt2(), EulerFaDdtScheme< Type >::facDdt(), backwardFaDdtScheme< Type >::facDdt(), boundedBackwardFaDdtScheme::facDdt(), backwardFaDdtScheme< Type >::facDdt0(), boundedBackwardFaDdtScheme::facDdt0(), gaussConvectionScheme< Type >::facDiv(), polyPatch::faceCellCentres(), cellQuality::faceNonOrthogonality(), cellQuality::faceSkewness(), gaussLaplacianScheme< Type >::facLaplacian(), EulerFaD2dt2Scheme< Type >::famD2dt2(), EulerFaDdtScheme< Type >::famDdt(), backwardFaDdtScheme< Type >::famDdt(), boundedBackwardFaDdtScheme::famDdt(), gaussConvectionScheme< Type >::famDiv(), gaussLaplacianScheme< Type >::famLaplacian(), Foam::edgeMeshTools::featureProximity(), adjointSpalartAllmaras::FISensitivityTerm(), adjointkOmegaSST::FISensitivityTerm(), volPointInterpolationAdjoint::flatBoundaryField(), volPointInterpolation::flatBoundaryField(), correctedSnGrad< Type >::fullGradCorrection(), faceCorrectedSnGrad< Type >::fullGradCorrection(), EulerDdtScheme< Type >::fvcDdt(), backwardDdtScheme< Type >::fvcDdt(), CoEulerDdtScheme< Type >::fvcDdt(), SLTSDdtScheme< Type >::fvcDdt(), CrankNicolsonDdtScheme< Type >::fvcDdt(), ddtScheme< Type >::fvcDdtPhiCoeff(), ddtScheme< Type >::fvcDdtPhiCoeffExperimental(), steadyStateDdtScheme< Type >::fvcDdtPhiCorr(), steadyStateDdtScheme< Type >::fvcDdtUfCorr(), gaussConvectionScheme< Type >::fvcDiv(), gaussLaplacianScheme< Type, GType >::fvcLaplacian(), relaxedNonOrthoGaussLaplacianScheme< Type, GType >::fvcLaplacian(), EulerD2dt2Scheme< Type >::fvmD2dt2(), EulerDdtScheme< Type >::fvmDdt(), backwardDdtScheme< Type >::fvmDdt(), CoEulerDdtScheme< Type >::fvmDdt(), SLTSDdtScheme< Type >::fvmDdt(), localEulerDdtScheme< Type >::fvmDdt(), gaussConvectionScheme< Type >::fvmDiv(), gaussLaplacianScheme< Type, GType >::fvmLaplacian(), relaxedNonOrthoGaussLaplacianScheme< Type, GType >::fvmLaplacian(), gaussLaplacianScheme< Type, GType >::fvmLaplacianUncorrected(), relaxedNonOrthoGaussLaplacianScheme< Type, GType >::fvmLaplacianUncorrected(), heThermo< BasicSolidThermo, MixtureType >::gamma(), multiphaseInterSystem::gamma(), pyrolysisChemistryModel< CompType, SolidThermo, GasThermo >::gasHs(), MMA::gConstr(), fvMeshDistribute::generateTestField(), NURBS3DVolume::getDxCellsDb(), NURBS3DVolume::getDxDb(), ATCstandard::getFISensitivityTerm(), MMA::getOrDefaultScalarField(), cylindrical::globalToLocal(), kinematicSingleLayer::gNormClipped(), Foam::fac::grad(), heThermo< BasicSolidThermo, MixtureType >::hc(), multiphaseInterSystem::hc(), heThermo< BasicSolidThermo, MixtureType >::he(), MassTransferPhaseSystem< BasePhaseSystem >::heatTransfer(), AnisothermalPhaseModel< BasePhaseModel >::heEqn(), LBFGS::HessianVectorProduct(), heheuPsiThermo< BasicPsiThermo, MixtureType >::heu(), coalCloudList::hsTrans(), BreenWestwater::htcFilmBoil(), Bromley::htcFilmBoil(), InterfaceCompositionPhaseChangePhaseSystem< BasePhaseSystem >::iDmdt(), pointVolInterpolation::interpolate(), localMax< Type >::interpolate(), localMin< Type >::interpolate(), edgeInterpolationScheme< scalar >::interpolate(), surfaceInterpolationScheme< GType >::interpolate(), volPointInterpolationAdjoint::interpolateSensitivitiesField(), Foam::inv(), LBFGS::invHessianVectorProduct(), ISQP::invHFL(), ReynoldsStress< RASModel< BasicTurbulenceModel > >::k(), multiphaseInterSystem::K(), adjointkOmegaSST::kaEqnSourceFromCDkOmega(), heSolidThermo< BasicSolidThermo, MixtureType >::Kappa(), liquidFilmThermo::kappa(), constantFilmThermo::kappa(), multiphaseInterSystem::kappa(), kineticGasEvaporation< Thermo, OtherThermo >::Kexp(), interfaceOxideRate< Thermo, OtherThermo >::Kexp(), boundaryAdjointContributionIncompressible::laminarDiffusivity(), Foam::levelSetFraction(), optimisationManager::lineSearchUpdate(), lnGradScheme< Type >::lnGrad(), Foam::fvc::magSqrGradGrad(), volPointInterpolationAdjoint::makeWeights(), cyclicACMIFvPatchField< Type >::manipulateMatrix(), cyclicAMIFvPatchField< scalar >::manipulateMatrix(), mappedPatchFieldBase< scalar >::mappedInternalField(), mappedPatchFieldBase< scalar >::mappedWeightField(), meshToMesh::mapSrcToTgt(), meshToMesh::mapTgtToSrc(), ISQP::matrixVectorProduct(), momentOfInertia::meshInertia(), CoEulerDdtScheme< Type >::meshPhi(), SLTSDdtScheme< Type >::meshPhi(), localEulerDdtScheme< Type >::meshPhi(), Jeschar::MHF(), regionModel1D::moveMesh(), liquidFilmThermo::mu(), constantFilmThermo::mu(), multiphaseInterSystem::mu(), heheuPsiThermo< BasicPsiThermo, MixtureType >::mub(), heheuPsiThermo< BasicPsiThermo, MixtureType >::muu(), Foam::fac::ndiv(), multiphaseSystem::nearInterface(), faPatchField< Type >::New(), fvPatchField< vector >::New(), Foam::fac::ngrad(), cellQuality::nonOrthogonality(), oversetFvMeshBase::normalisation(), Schaeffer::nu(), JohnsonJacksonSchaeffer::nu(), multiphaseSystem::nu(), multiphaseInterSystem::nu(), consumptionSpeed::omega0Sigma(), anisotropicFilter::operator()(), optionList::operator()(), RaviPetersen::operator()(), MMA::p(), jumpCyclicAMIFvPatchField< scalar >::patchNeighbourField(), cyclicFaPatchField< Type >::patchNeighbourField(), cyclicFvPatchField< vector >::patchNeighbourField(), topODesignVariables::penalty(), liquidFilmBase::pg(), MMA::pLamda(), Foam::pow(), phasePressureModel::pPrime(), phasePressureModel::pPrimef(), boundaryAdjointContributionIncompressible::pressureSource(), filmTurbulenceModel::primaryRegionFriction(), heheuPsiThermo< BasicPsiThermo, MixtureType >::psib(), heheuPsiThermo< BasicPsiThermo, MixtureType >::psiu(), MMA::q(), laminar< ReactionThermo >::Qdot(), EDC< ReactionThermo >::Qdot(), diffusionMulticomponent< ReactionThermo, ThermoType >::Qdot(), solidChemistryModel< CompType, SolidThermo >::Qdot(), StandardChemistryModel< CompType, ThermoType >::Qdot(), MMA::qLamda(), Kutadeladze::qNucleate(), greyDiffusiveViewFactorFixedValueFvPatchScalarField::qro(), nonlinearEddyViscosity< incompressible::RASModel >::R(), laminar< ReactionThermo >::R(), diffusionMulticomponent< ReactionThermo, ThermoType >::R(), reader::readField(), Foam::fvc::reconstructMag(), MRFZoneList::relative(), ISQP::resFGs(), ISQP::resFL(), faMatrix< Type >::residual(), fvMatrix< Type >::residual(), constantFilmThermo::rho(), multiphaseInterSystem::rho(), KinematicCloud< Cloud< basicKinematicCollidingParcel > >::rhoEff(), coalCloudList::rhoTrans(), fvDOM::Rp(), pyrolysisChemistryModel< CompType, SolidThermo, GasThermo >::RRg(), solidChemistryModel< CompType, SolidThermo >::RRs(), solidChemistryModel< CompType, SolidThermo >::RRsHs(), eddyDissipationDiffusionModel< ReactionThermo, ThermoType >::rtDiff(), fvDOM::Ru(), kOmegaSSTDDES< BasicTurbulenceModel >::S2(), kOmegaSSTDES< BasicTurbulenceModel >::S2(), coalCloudList::Sh(), ThermoCloud< Foam::DSMCCloud >::Sh(), thermoSingleLayer::Sh(), ISQP::ShermanMorrisonRank1Update(), primaryRadiation::Shs(), standardRadiation::Shs(), constantRadiation::Shs(), liquidFilmThermo::sigma(), constantFilmThermo::sigma(), electrostaticDepositionFvPatchScalarField::sigma(), cloudScatter::sigmaEff(), ThermoCloud< Foam::DSMCCloud >::sigmap(), skewCorrected< Type >::skewCorrection(), cellQuality::skewness(), snGradScheme< Type >::snGrad(), twoPhaseSystem::solve(), surfaceAlignedSBRStressFvMotionSolver::solve(), thermalBaffle::solveEnergy(), fvMatrix< Type >::solveSegregated(), optionList::source(), noiseModel::SPL(), LBFGS::SR1HessianVectorProduct(), coalCloudList::Srho(), ReactingCloud< Foam::DSMCCloud >::Srho(), thermoSingleLayer::Srho(), Foam::stabilise(), regionFunctionObject::store(), regionFunctionObject::storeInDb(), coalCloudList::SU(), KinematicCloud< Cloud< basicKinematicCollidingParcel > >::SU(), Foam::fvc::surfaceIntegrate(), surfaceNormalFixedValueFvPatchVectorField::surfaceNormalFixedValueFvPatchVectorField(), Foam::fvc::surfaceSum(), multiphaseSystem::surfaceTension(), multiphaseSystem::Svm(), coalCloudList::SYi(), ReactingCloud< Foam::DSMCCloud >::SYi(), thermoSingleLayer::T(), boundaryAdjointContributionIncompressible::tangentVelocitySource(), StandardChemistryModel< CompType, ThermoType >::tc(), heThermo< BasicSolidThermo, MixtureType >::THE(), temperatureDependentContactAngleForce::theta(), distributionContactAngleForce::theta(), perturbedTemperatureDependentContactAngleForce::theta(), KinematicCloud< Cloud< basicKinematicCollidingParcel > >::theta(), Foam::transform(), sixDoFRigidBodyMotion::transform(), Foam::transformPoints(), rigidBodyMotion::transformPoints(), polynomial::Tsat(), function1::Tsat(), phaseSystem::U(), designVariablesUpdate::update(), inverseDistance::update(), objectiveForce::update_dxdbMultiplier(), objectiveMoment::update_dxdbMultiplier(), adjointFarFieldVelocityFvPatchVectorField::updateCoeffs(), adjointWallVelocityLowReFvPatchVectorField::updateCoeffs(), adjointOutletPressureFvPatchScalarField::updateCoeffs(), adjointFarFieldPressureFvPatchScalarField::updateCoeffs(), surfaceNormalFixedValueFvPatchVectorField::updateCoeffs(), uniformNormalFixedValueFvPatchVectorField::updateCoeffs(), lumpedMassWallTemperatureFvPatchScalarField::updateCoeffs(), turbulentTemperatureCoupledBaffleMixedFvPatchScalarField::updateCoeffs(), timeVaryingMassSorptionFvPatchScalarField::updateCoeffs(), enthalpySorptionFvPatchScalarField::updateCoeffs(), electrostaticDepositionFvPatchScalarField::updateCoeffs(), designVariablesUpdate::updateGradientsAndValues(), laminar::Us(), liquidFilmBase::Us(), coalCloudList::UTrans(), liquidFilmBase::Uw(), KinematicCloud< Cloud< basicKinematicCollidingParcel > >::vDotSweep(), boundaryAdjointContributionIncompressible::velocitySource(), MassTransferPhaseSystem< BasePhaseSystem >::volTransfer(), adjointkOmegaSST::waEqnSourceFromCDkOmega(), midPoint< Type >::weights(), outletStabilised< Type >::weights(), faNVDscheme< Type, NVDweight >::weights(), limitedSurfaceInterpolationScheme< Type >::weights(), triSurfaceTools::writeCurvature(), Foam::edgeMeshTools::writeFeatureProximity(), Foam::ensightOutput::writeVolField(), nutUWallFunctionFvPatchScalarField::yPlus(), MRFZoneList::zeroFilter(), and wallLubricationModel::zeroGradWalls().

◆ constCast()

T& constCast ( ) const
inline

Return non-const reference to the object or to the contents of a (non-null) managed pointer, with an additional const_cast.

Fatal for a null pointer.

Definition at line 297 of file tmp.H.

Referenced by LESfilter::correctBoundaryConditions(), waveVelocityFvPatchVectorField::updateCoeffs(), and waveAlphaFvPatchScalarField::updateCoeffs().

Here is the caller graph for this function:

◆ ptr()

◆ clear()

void clear ( ) const
inlinenoexcept

If object pointer points to valid object: delete object and set pointer to nullptr.

Definition at line 289 of file tmpI.H.

Referenced by MRFZoneList::absolute(), incompressibleAdjointSolver::accumulateGradDxDbMultiplier(), boundBox::add(), adjointkOmegaSST::adjointMeanFlowSource(), lduMatrix::Amul(), Implicit< CloudType >::cacheFields(), kEqn< BasicTurbulenceModel >::correct(), LamBremhorstKE::correct(), LienLeschziner::correct(), kOmega< BasicTurbulenceModel >::correct(), dynamicKEqn< BasicTurbulenceModel >::correct(), kEpsilon< EddyDiffusivity< compressible::turbulenceModel > >::correct(), RNGkEpsilon< BasicTurbulenceModel >::correct(), LaunderSharmaKE< BasicTurbulenceModel >::correct(), kEpsilonLopesdaCosta< BasicTurbulenceModel >::correct(), SpalartAllmarasBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::correct(), EBRSM< BasicTurbulenceModel >::correct(), mixtureKEpsilon< BasicTurbulenceModel >::correct(), kEpsilonPhitF< BasicTurbulenceModel >::correct(), kOmegaSSTBase< eddyViscosity< RASModel< BasicTurbulenceModel > > >::correct(), kL< BasicTurbulenceModel >::correct(), kOmegaSSTLM< BasicTurbulenceModel >::correctReThetatGammaInt(), triSurfaceTools::curvatures(), Foam::fvc::DDt(), Foam::fvm::div(), Foam::fam::div(), Foam::fvc::div(), Foam::fac::div(), adjointkOmegaSST::divUMeanFlowSource(), edgeInterpolationScheme< scalar >::euclidianInterpolate(), adjointSpalartAllmaras::FISensitivityTerm(), Foam::fvc::flux(), fft::forwardTransform(), updateMethod::globalSum(), leastSquaresEdgeInterpolation< Type >::interpolate(), fvMeshSubsetProxy::interpolate(), edgeInterpolationScheme< scalar >::interpolate(), surfaceInterpolationScheme< GType >::interpolate(), Foam::inv(), Foam::fac::laplacian(), Foam::fam::laplacian(), meshedSurfRef::movePoints(), Foam::fam::ndiv(), Foam::fac::ndiv(), adjointkOmegaSST::nutMeanFlowSource(), anisotropicFilter::operator()(), noiseFFT::Pf(), PatchToPatchInterpolation< FromPatch, ToPatch >::pointInterpolate(), realizableKE< BasicTurbulenceModel >::rCmu(), fft::realTransform1D(), Foam::fvc::reconstructMag(), MRFZoneList::relative(), fft::reverseTransform(), snGradScheme< Type >::snGrad(), Foam::stabilise(), lduMatrix::Tmul(), Foam::transform(), PatchFunction1< Foam::vector >::transform(), Foam::transformPoints(), objectiveForce::update_dxdbMultiplier(), objectiveMoment::update_dxdbMultiplier(), Foam::fvc::volumeIntegrate(), Foam::writeAreaFields(), Foam::writeDimFields(), Foam::writePointField(), and Foam::writeVolFields().

◆ protect()

void protect ( bool  on)
inlinenoexcept

Use specified protection against moving for the managed pointer. No-op for references.

Definition at line 307 of file tmpI.H.

Referenced by regIOobject::store().

Here is the caller graph for this function:

◆ reset() [1/4]

◆ reset() [2/4]

void reset ( T p = nullptr)
inlinenoexcept

Delete managed temporary object and set to new given pointer.

Definition at line 329 of file tmpI.H.

◆ reset() [3/4]

void reset ( const autoPtr< T > &  )
delete

Avoid inadvertent casting (to object or pointer)

◆ reset() [4/4]

void reset ( const refPtr< T > &  )
delete

Avoid inadvertent casting (to object)

◆ emplace()

T & emplace ( Args &&...  args)
inline

Reset with emplace construction. Return reference to the new content.

Definition at line 357 of file tmpI.H.

Referenced by sampledSets::getOrLoadField(), and probes::getOrLoadField().

Here is the caller graph for this function:

◆ cref() [2/6]

void cref ( const tmp< T > &  other)
inlinenoexcept

Clear existing and set (const) reference from other.

Definition at line 367 of file tmpI.H.

◆ cref() [3/6]

void cref ( const T obj)
inlinenoexcept

Clear existing and set (const) reference.

Definition at line 382 of file tmpI.H.

◆ cref() [4/6]

void cref ( const T p)
inlinenoexcept

Clear existing and set (const) reference to pointer content.

The pointer can be null, which is handled like a clear().

Definition at line 391 of file tmpI.H.

◆ cref() [5/6]

void cref ( const autoPtr< T > &  )
delete

Avoid inadvertent casting (to object or pointer)

◆ cref() [6/6]

void cref ( const refPtr< T > &  )
delete

Avoid inadvertent casting (to object)

◆ ref() [2/5]

void ref ( T obj)
inlinenoexcept

Clear existing and set to (non-const) reference.

Definition at line 400 of file tmpI.H.

◆ ref() [3/5]

void ref ( T p)
inlinenoexcept

Clear existing and set (non-const) reference to pointer content.

The pointer can be null, which is handled like a clear().

Definition at line 409 of file tmpI.H.

◆ ref() [4/5]

void ref ( const autoPtr< T > &  )
delete

Avoid inadvertent casting (to object or pointer)

◆ ref() [5/5]

void ref ( const refPtr< T > &  )
delete

Avoid inadvertent casting (to object)

◆ swap()

void swap ( tmp< T > &  other)
inlinenoexcept

Swaps the managed object with other.

Definition at line 418 of file tmpI.H.

Referenced by FilterField::evaluate().

Here is the caller graph for this function:

◆ operator->() [1/2]

const T * operator-> ( ) const
inline

Dereferences (const) pointer to the managed object.

Fatal for a null managed pointer.

Definition at line 435 of file tmpI.H.

◆ operator->() [2/2]

T * operator-> ( )
inline

Dereferences (non-const) pointer to the managed object.

Fatal for a null managed pointer or if the object is const.

Definition at line 449 of file tmpI.H.

◆ operator()()

const T& operator() ( ) const
inline

Return const reference to the object - same as cref() method.

Definition at line 424 of file tmp.H.

◆ operator bool()

operator bool ( ) const
inlineexplicitnoexcept

True if pointer/reference is non-null. Same as good()

Definition at line 432 of file tmp.H.

◆ operator const T &()

operator const T & ( ) const
inline

Cast to underlying data type, using the cref() method.

Definition at line 437 of file tmp.H.

References tmp< T >::cref().

Here is the call graph for this function:

◆ operator=() [1/4]

void operator= ( const tmp< T > &  other)
inline

Transfer ownership of the managed pointer.

Fatal for a null managed pointer or if the object is const.

Definition at line 470 of file tmpI.H.

◆ operator=() [2/4]

void operator= ( tmp< T > &&  other)
inlinenoexcept

Clear existing and transfer ownership.

Definition at line 507 of file tmpI.H.

◆ operator=() [3/4]

void operator= ( T p)
inline

Take ownership of the pointer.

Fatal for a null pointer, or when the pointer is non-unique.

Definition at line 525 of file tmpI.H.

◆ operator=() [4/4]

void operator= ( std::nullptr_t  )
inlinenoexcept

Reset via assignment from literal nullptr.

Definition at line 464 of file tmp.H.

◆ valid()

◆ isTmp()

bool isTmp ( ) const
inlinenoexcept

Identical to is_pointer(). Prefer is_pointer() or movable().

Deprecated:
(2020-07) - prefer is_pointer() or movable()

Definition at line 480 of file tmp.H.

◆ empty()

bool empty ( ) const
inlinenoexcept

Deprecated(2020-07) True if a null managed pointer.

Deprecated:
(2020-07) - use bool operator

Definition at line 489 of file tmp.H.


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