PtrList< T > Class Template Reference

A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers. The operator[] returns a reference to the object, not the pointer. More...

Inherits UPtrList< T >.

Inherited by CloudFunctionObjectList< KinematicCloud< Foam::DSMCCloud > >, CloudFunctionObjectList< KinematicCloud< CloudType > >, CloudFunctionObjectList< KinematicCloud< Cloud< basicKinematicCollidingParcel > > >, DictionaryBase< PtrList< T >, T >, FieldField< PatchField, Type >, FieldField< fvPatchField, symmTensor >, FieldField< fvPatchField, scalar >, FieldField< pointPatchField, Type >, FieldField< fvPatchField, vector >, FieldField< fvPatchField, tensor >, FieldField< Foam::fvPatchField, scalar >, FieldField< Foam::fvPatchField, Foam::Vector >, FieldField< Foam::pointPatchField, Foam::Vector >, FieldField< Field, Foam::Vector >, FieldField< Field, scalar >, FieldField< Foam::Field, scalar >, FieldField< Foam::Field, LUType >, FieldField< fvsPatchField, scalar >, FieldField< pointPatchField, scalar >, FieldField< pointPatchField, vector >, FieldField< faPatchField, scalar >, FieldField< Foam::faPatchField, scalar >, FieldField< Foam::faePatchField, scalar >, FieldField< Foam::faPatchField, Foam::Vector >, FieldField< Foam::faePatchField, Foam::Vector >, FieldField< Foam::faPatchField, Foam::SphericalTensor >, FieldField< Foam::faePatchField, Foam::SphericalTensor >, FieldField< Foam::faPatchField, Foam::SymmTensor >, FieldField< Foam::faePatchField, Foam::SymmTensor >, FieldField< Foam::faPatchField, Foam::Tensor >, FieldField< Foam::faePatchField, Foam::Tensor >, FieldField< Foam::Field, Type >, FieldField< Foam::Field, Foam::Tensor >, FieldField< Foam::fvsPatchField, scalar >, FieldField< Foam::fvsPatchField, Foam::Vector >, FieldField< Foam::fvPatchField, Foam::SphericalTensor >, FieldField< Foam::fvsPatchField, Foam::SphericalTensor >, FieldField< Foam::fvPatchField, Foam::SymmTensor >, FieldField< Foam::fvsPatchField, Foam::SymmTensor >, FieldField< Foam::fvPatchField, Foam::Tensor >, FieldField< Foam::fvsPatchField, Foam::Tensor >, FieldField< Foam::fvPatchField, Type >, FieldField< Foam::pointPatchField, Type >, FieldField< Foam::fvsPatchField, Type >, FieldField< fvsPatchField, vector >, FieldField< Foam::pointPatchField, scalar >, FieldField< Foam::pointPatchField, Foam::SphericalTensor >, FieldField< Foam::pointPatchField, Foam::SymmTensor >, FieldField< Foam::pointPatchField, Foam::Tensor >, FieldField< faPatchField, tensor >, FieldField< faPatchField, vector >, FieldField< faePatchField, scalar >, IOPtrList< Foam::entry >, InjectionModelList< Foam::KinematicCloud< Foam::DSMCCloud > >, ParticleForceList< KinematicCloud< Foam::DSMCCloud > >, ParticleForceList< KinematicCloud< CloudType > >, ParticleForceList< KinematicCloud< Cloud< basicKinematicCollidingParcel > > >, PtrDynList< Foam::Field< label > >, PtrDynList< Foam::Field< scalar > >, PtrDynList< Foam::Field< Foam::Vector > >, PtrDynList< Foam::Field< Foam::SphericalTensor > >, PtrDynList< Foam::Field< Foam::SymmTensor > >, PtrDynList< Foam::Field< Foam::Tensor > >, PtrDynList< Foam::profilingInformation >, ZoneMesh< pointZone, polyMesh >, ZoneMesh< faceZone, polyMesh >, ZoneMesh< cellZone, polyMesh >, IOPtrList< T >, PtrDynList< T, SizeMin >, faBoundaryMesh, fvBoundaryMesh, pointBoundaryMesh, and polyBoundaryMesh.

Collaboration diagram for PtrList< T >:
[legend]

Public Member Functions

constexpr PtrList () noexcept
 Default construct. More...
 
 PtrList (const label len)
 Construct with specified size, each element initialized to nullptr. More...
 
 PtrList (const PtrList< T > &list)
 Copy construct using 'clone()' method on each element. More...
 
 PtrList (PtrList< T > &&list)
 Move construct. More...
 
 PtrList (UList< T * > &list)
 Take ownership of pointers in the list, set old pointers to null. More...
 
template<class CloneArg >
 PtrList (const PtrList< T > &list, const CloneArg &cloneArgs)
 Copy construct using 'clone()' method on each element. More...
 
 PtrList (PtrList< T > &list, bool reuse)
 Construct as copy or re-use as specified. More...
 
 PtrList (const SLPtrList< T > &list)
 Copy construct using 'clone()' on each element of SLPtrList<T> More...
 
template<class INew >
 PtrList (Istream &is, const INew &inew)
 Construct from Istream using given Istream constructor class. More...
 
 PtrList (Istream &is)
 Construct from Istream using default Istream constructor class. More...
 
 ~PtrList ()
 Destructor. More...
 
template<class... Args>
PtrList< Tclone (Args &&... args) const
 Make a copy by cloning each of the list elements. More...
 
const Tset (const label i) const
 
void clear ()
 Clear the PtrList. Delete allocated entries and set size to zero. More...
 
void resize (const label newLen)
 Adjust size of PtrList. More...
 
void setSize (const label newLen)
 Same as resize() More...
 
template<class... Args>
void emplace_append (Args &&... args)
 Construct and append an element to the end of the list. More...
 
void append (T *ptr)
 Append an element to the end of the list. More...
 
void append (autoPtr< T > &ptr)
 Move append an element to the end of the list. More...
 
void append (autoPtr< T > &&ptr)
 Move append an element to the end of the list. More...
 
void append (std::unique_ptr< T > &&ptr)
 Move append an element to the end of the list. More...
 
void append (const refPtr< T > &ptr)
 Move or clone append a refPtr to the end of the list. More...
 
void append (const tmp< T > &ptr)
 Move or clone append a tmp to the end of the list. More...
 
void append (PtrList< T > &&other)
 Move append another list to the end of this list. More...
 
template<class... Args>
autoPtr< Templace (const label i, Args &&... args)
 Construct and set an element. More...
 
autoPtr< Tset (const label i, T *ptr)
 Set element to given pointer and return old element (can be null) More...
 
autoPtr< Tset (const label i, autoPtr< T > &ptr)
 Set element to given autoPtr and return old element. More...
 
autoPtr< Tset (const label i, autoPtr< T > &&ptr)
 Set element to given autoPtr and return old element. More...
 
autoPtr< Tset (const label i, std::unique_ptr< T > &&ptr)
 Set element to given unique_ptr and return old element. More...
 
autoPtr< Tset (const label i, const refPtr< T > &ptr)
 Set element to given refPtr and return old element. More...
 
autoPtr< Tset (const label i, const tmp< T > &ptr)
 Set element to given tmp and return old element. More...
 
autoPtr< Trelease (const label i)
 Release ownership of the pointer at the given position. More...
 
void transfer (PtrList< T > &list)
 Transfer into this list and annul the argument list. More...
 
void operator= (const PtrList< T > &list)
 Copy assignment. More...
 
void operator= (PtrList< T > &&list)
 Move assignment. More...
 
template<class... Args>
Foam::PtrList< Tclone (Args &&... args) const
 
template<class... Args>
Foam::autoPtr< Templace (const label i, Args &&... args)
 
- Public Member Functions inherited from UPtrList< T >
constexpr UPtrList () noexcept
 Default construct. More...
 
 UPtrList (const label len)
 Construct with specified size, each element initialized to nullptr. More...
 
 UPtrList (const UPtrList< T > &list)
 Copy construct (shallow copies addresses) More...
 
 UPtrList (UPtrList< T > &&list)
 Move construct. More...
 
 UPtrList (UPtrList< T > &list, bool reuse)
 Construct as shallow copy or re-use as specified. More...
 
 UPtrList (PtrList< T > &list)
 Shallow copy from PtrList. More...
 
 UPtrList (const UList< T * > &list)
 Construct from UList of pointers (shallow copy) More...
 
 UPtrList (UList< T > &list)
 Construct from UList, taking the address of each list element. More...
 
label size () const noexcept
 The number of elements in the list. More...
 
bool empty () const noexcept
 True if the list is empty (ie, size() is zero) More...
 
Tfirst ()
 Return reference to the first element of the list. More...
 
const Tfirst () const
 Return reference to first element of the list. More...
 
Tlast ()
 Return reference to the last element of the list. More...
 
const Tlast () const
 Return reference to the last element of the list. More...
 
const Ttest (const label i) const
 
Tget (const label i)
 
const Tget (const label i) const
 
const Tset (const label i) const
 
void clear ()
 Set list size to zero. More...
 
void resize (const label newLen)
 Change the size of the list. More...
 
void setSize (const label n)
 Alias for resize() More...
 
label squeezeNull ()
 Squeeze out intermediate nullptr entries in the list of pointers. More...
 
void append (T *ptr)
 Append an element to the end of the list. More...
 
void append (UPtrList< T > &&other)
 Move append another list to the end of this list. More...
 
void swap (UPtrList< T > &list)
 Swap content. More...
 
void transfer (UPtrList< T > &list)
 Transfer contents into this list and annul the argument. More...
 
Tset (const label i, T *ptr)
 
void reorder (const labelUList &oldToNew, const bool check=false)
 
void sortOrder (const labelUList &order, const bool check=false)
 
void checkNonNull () const
 Check and raise FatalError if any nullptr exists in the list. More...
 
const Toperator[] (const label i) const
 Return const reference to the element. More...
 
Toperator[] (const label i)
 Return reference to the element. More...
 
const Toperator() (const label i) const
 Return const pointer to the element - same as get(). More...
 
void operator= (const UPtrList< T > &list)
 Copy assignment (shallow copies addresses) More...
 
void operator= (UPtrList< T > &&list)
 Move assignment. More...
 
T ** begin_ptr () noexcept
 Iterator to begin of raw pointers traversal (use with caution) More...
 
T ** end_ptr () noexcept
 Iterator beyond end of raw pointers traversal (use with caution) More...
 
iterator begin () noexcept
 Return an iterator to begin of UPtrList traversal. More...
 
iterator end () noexcept
 Return iterator beyond end of UPtrList traversal. More...
 
const_iterator cbegin () const noexcept
 Return const_iterator to begin of UPtrList traversal. More...
 
const_iterator cend () const noexcept
 Return const_iterator beyond end of UPtrList traversal. More...
 
const_iterator begin () const noexcept
 Return const_iterator to begin of UPtrList traversal. More...
 
const_iterator end () const noexcept
 Return const_iterator beyond end of UPtrList traversal. More...
 

Protected Member Functions

template<class INew >
void readIstream (Istream &is, const INew &inew)
 Read from Istream using Istream constructor class. More...
 
void free ()
 Delete the allocated entries, but retain the list size. More...
 
- Protected Member Functions inherited from UPtrList< T >
void setAddressableSize (const label n) noexcept
 Adjust addressable size. More...
 
 UPtrList (Detail::PtrListDetail< T > &&ptrs)
 Low-level move construct. More...
 

Friends

Istreamoperator>> (Istream &is, PtrList< T > &list)
 Read from Istream, discarding contents of existing list. More...
 

Additional Inherited Members

- Public Types inherited from UPtrList< T >
typedef T value_type
 Type of values the list contains. More...
 
typedef Treference
 A non-const reference to the value_type. More...
 
typedef const Tconst_reference
 A const reference to the value_type. More...
 
- Protected Attributes inherited from UPtrList< T >
Detail::PtrListDetail< Tptrs_
 The list of pointers. More...
 

Detailed Description

template<class T>
class Foam::PtrList< T >

A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers. The operator[] returns a reference to the object, not the pointer.

See also
Foam::UPtrList Foam::PtrDynList
Source files

Definition at line 70 of file PtrList.H.

Constructor & Destructor Documentation

◆ PtrList() [1/10]

constexpr PtrList
inlineconstexprnoexcept

Default construct.

Definition at line 45 of file PtrListI.H.

◆ PtrList() [2/10]

PtrList ( const label  len)
inlineexplicit

Construct with specified size, each element initialized to nullptr.

Definition at line 52 of file PtrListI.H.

◆ PtrList() [3/10]

PtrList ( const PtrList< T > &  list)
inline

Copy construct using 'clone()' method on each element.

Definition at line 59 of file PtrListI.H.

◆ PtrList() [4/10]

PtrList ( PtrList< T > &&  list)
inline

Move construct.

Definition at line 66 of file PtrListI.H.

◆ PtrList() [5/10]

PtrList ( UList< T * > &  list)
inlineexplicit

Take ownership of pointers in the list, set old pointers to null.

Definition at line 73 of file PtrListI.H.

References T.

◆ PtrList() [6/10]

PtrList ( const PtrList< T > &  list,
const CloneArg &  cloneArgs 
)
inline

Copy construct using 'clone()' method on each element.

Definition at line 84 of file PtrListI.H.

◆ PtrList() [7/10]

PtrList ( PtrList< T > &  list,
bool  reuse 
)

Construct as copy or re-use as specified.

Definition at line 36 of file PtrList.C.

References PtrList< T >::clone(), UPtrList< T >::ptrs_, and UPtrList< T >::size().

Here is the call graph for this function:

◆ PtrList() [8/10]

PtrList ( const SLPtrList< T > &  list)
explicit

Copy construct using 'clone()' on each element of SLPtrList<T>

Definition at line 54 of file PtrList.C.

References LPtrList< LListBase, T >::cbegin(), LPtrList< LListBase, T >::cend(), and UPtrList< T >::ptrs_.

Here is the call graph for this function:

◆ PtrList() [9/10]

PtrList ( Istream is,
const INew inew 
)

Construct from Istream using given Istream constructor class.

Definition at line 145 of file PtrListIO.C.

◆ PtrList() [10/10]

PtrList ( Istream is)

Construct from Istream using default Istream constructor class.

Definition at line 152 of file PtrListIO.C.

◆ ~PtrList()

Destructor.

Definition at line 72 of file PtrList.C.

Member Function Documentation

◆ readIstream()

void readIstream ( Istream is,
const INew inew 
)
protected

Read from Istream using Istream constructor class.

Definition at line 38 of file PtrListIO.C.

References clear(), IOstream::fatalCheck(), FUNCTION_NAME, token::isLabel(), token::labelToken(), p, Istream::readBeginList(), resize(), and T.

Referenced by IOPtrList< T >::IOPtrList(), and IOPtrList< Foam::entry >::operator=().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ free()

void free
inlineprotected

Delete the allocated entries, but retain the list size.

Definition at line 36 of file PtrListI.H.

◆ clone() [1/2]

PtrList< T > clone ( Args &&...  args) const

Make a copy by cloning each of the list elements.

Referenced by attachPolyTopoChanger::attach(), faMeshDistributor::distribute(), fvMeshTools::newMesh(), and PtrList< T >::PtrList().

Here is the caller graph for this function:

◆ set() [1/7]

const T * set ( const label  i) const
inline

Return const pointer to element (can be nullptr), without bounds checking - same as get().

The return value can be tested as a bool.

Definition at line 138 of file PtrList.H.

Referenced by isoSurfacePoint::adaptPatchFields(), fvMeshAdder::add(), polyMeshAdder::add(), surfaceZonesInfo::addCellZone(), cellTable::addCellZones(), surfaceZonesInfo::addFaceZone(), phaseSystem::addField(), meshRefinement::addPointZone(), meshRefinement::appendPatch(), viewFactor::calculate(), boundaryMesh::changeFaces(), boundaryMesh::changePatchType(), ZoneMesh< pointZone, polyMesh >::checkDefinition(), adjointSolverManager::constraintSensitivities(), diffusionMulticomponent< ReactionThermo, ThermoType >::correct(), directionalPressureGradientExplicitSource::correct(), cyclicACMIFvPatchField< Type >::cyclicACMIFvPatchField(), MomentumTransferPhaseSystem< BasePhaseSystem >::ddtCorrByAs(), faFieldDecomposer::decomposeField(), fvFieldDecomposer::decomposeField(), pointFieldDecomposer::decomposeField(), boundaryMesh::deletePatch(), faMeshDistributor::distribute(), fvMeshDistribute::distribute(), faMeshDistributor::distributeField(), extrudePatchMesh::extrudePatchMesh(), forAll(), GAMGSolver::GAMGSolver(), lduPrimitiveMesh::gather(), GeometricBoundaryField< Type, PatchField, GeoMesh >::GeometricBoundaryField(), surfaceZonesInfo::getAllClosedNamedSurfaces(), surfaceZonesInfo::getClosedNamedSurfaces(), surfaceZonesInfo::getInsidePointNamedSurfaces(), surfaceZonesInfo::getNamedSurfaces(), surfaceZonesInfo::getStandaloneNamedSurfaces(), surfaceZonesInfo::getUnclosedNamedSurfaces(), GAMGProcAgglomeration::globalCellCells(), lduPrimitiveMesh::globalCellCells(), interRegionExplicitPorositySource::initialise(), viewFactor::initialise(), PDRblock::innerMesh(), faMeshSubset::interpolate(), singleCellFvMesh::interpolate(), fvMeshSubset::interpolate(), meshToMesh0::interpolate(), isoSurfacePoint::isoSurfacePoint(), fvMeshTools::loadOrCreateMesh(), faMeshTools::loadOrCreateMesh(), LUscalarMatrix::LUscalarMatrix(), polyTopoChange::makeMesh(), fvMeshAdder::MapDimFields(), meshToMesh::mapSrcToTgt(), fvMeshAdder::MapSurfaceFields(), meshToMesh::mapTgtToSrc(), fvMeshAdder::MapVolFields(), MomentumTransferPhaseSystem< BasePhaseSystem >::momentumTransferf(), multiComponentMixture< ThermoType >::multiComponentMixture(), faMeshTools::newMesh(), MomentumTransferPhaseSystem< BasePhaseSystem >::partialElimination(), MomentumTransferPhaseSystem< BasePhaseSystem >::partialEliminationf(), PDRblock::PDRblock(), pointBoundaryMesh::pointBoundaryMesh(), polyBoundaryMesh::polyBoundaryMesh(), polyMesh::polyMesh(), RecycleInteraction< CloudType >::postEvolve(), powerLawLopesdaCostaZone::powerLawLopesdaCostaZone(), pyrolysisChemistryModel< CompType, SolidThermo, GasThermo >::pyrolysisChemistryModel(), functionObjectList::read(), sampledSurfaces::read(), boundaryMesh::read(), externalCoupled::readDataMaster(), Foam::readLagrangian(), faFieldReconstructor::reconstructAreaField(), faFieldReconstructor::reconstructEdgeField(), faFieldReconstructor::reconstructField(), fvFieldReconstructor::reconstructField(), pointFieldReconstructor::reconstructField(), fvFieldReconstructor::reconstructInternalField(), pointFieldReconstructor::reconstructPointField(), processorMeshes::reconstructPoints(), fvFieldReconstructor::reconstructSurfaceField(), fvFieldReconstructor::reconstructVolumeField(), refinementSurfaces::refinementSurfaces(), refinementFeatures::regionEdgeTrees(), faMeshSubset::reset(), fvMeshSubset::reset(), multiphaseSystem::solve(), multiphaseSystem::solveAlphas(), MultiComponentPhaseModel< BasePhaseModel, phaseThermo >::solveYi(), ZoneMesh< pointZone, polyMesh >::sortedNames(), syncTools::syncFaceList(), blockMesh::topology(), inverseDistance::update(), trackingInverseDistance::update(), optimisationType::updateGradientsAndValues(), OFstreamCollator::write(), externalCoupled::writeDataMaster(), faMeshDecomposition::writeDecomposition(), cellZoneSet::writeObject(), faceZoneSet::writeObject(), pointZoneSet::writeObject(), and streamLineBase::writeToFile().

◆ clear()

◆ resize()

void resize ( const label  newLen)

Adjust size of PtrList.

New entries are initialized to nullptr, removed entries are deleted

Definition at line 103 of file PtrList.C.

Referenced by polyTopoChange::addMesh(), fvMeshTools::addPatch(), faMeshDistributor::distribute(), fvMeshTools::loadOrCreateMesh(), faMeshTools::loadOrCreateMesh(), faMeshTools::newMesh(), PDRblock::PDRblock(), polyBoundaryMesh::polyBoundaryMesh(), functionObjectList::read(), sampledSurfaces::read(), fvMeshSubset::reset(), and PtrList< T >::setSize().

Here is the caller graph for this function:

◆ setSize()

◆ emplace_append()

void emplace_append ( Args &&...  args)
inline

Construct and append an element to the end of the list.

Definition at line 106 of file PtrListI.H.

References outputOptions::append(), args, and T.

Here is the call graph for this function:

◆ append() [1/7]

void append ( T ptr)
inline

Append an element to the end of the list.

Definition at line 113 of file PtrListI.H.

References outputOptions::append().

Referenced by singleProcessorFaceSets::add(), FreeStream< CloudType >::FreeStream(), triSurfaceLoader::load(), rigidBodyMeshMotion::rigidBodyMeshMotion(), rigidBodyMeshMotionSolver::rigidBodyMeshMotionSolver(), and streamLineBase::trimToBox().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ append() [2/7]

void append ( autoPtr< T > &  ptr)
inline

Move append an element to the end of the list.

Definition at line 120 of file PtrListI.H.

References outputOptions::append(), and autoPtr< T >::release().

Here is the call graph for this function:

◆ append() [3/7]

void append ( autoPtr< T > &&  ptr)
inline

Move append an element to the end of the list.

Definition at line 127 of file PtrListI.H.

References outputOptions::append().

Here is the call graph for this function:

◆ append() [4/7]

void append ( std::unique_ptr< T > &&  ptr)
inline

Move append an element to the end of the list.

Definition at line 134 of file PtrListI.H.

References outputOptions::append().

Here is the call graph for this function:

◆ append() [5/7]

void append ( const refPtr< T > &  ptr)
inline

Move or clone append a refPtr to the end of the list.

Definition at line 141 of file PtrListI.H.

References outputOptions::append(), and refPtr< T >::ptr().

Here is the call graph for this function:

◆ append() [6/7]

void append ( const tmp< T > &  ptr)
inline

Move or clone append a tmp to the end of the list.

Definition at line 148 of file PtrListI.H.

References outputOptions::append(), and tmp< T >::ptr().

Here is the call graph for this function:

◆ append() [7/7]

void append ( PtrList< T > &&  other)
inline

Move append another list to the end of this list.

Definition at line 155 of file PtrListI.H.

◆ emplace() [1/2]

autoPtr< T > emplace ( const label  i,
Args &&...  args 
)
inline

Construct and set an element.

◆ set() [2/7]

Foam::autoPtr< T > set ( const label  i,
T ptr 
)
inline

Set element to given pointer and return old element (can be null)

No-op if the new pointer value is identical to the current content.

Definition at line 191 of file PtrListI.H.

◆ set() [3/7]

Foam::autoPtr< T > set ( const label  i,
autoPtr< T > &  ptr 
)
inline

Set element to given autoPtr and return old element.

Definition at line 202 of file PtrListI.H.

◆ set() [4/7]

Foam::autoPtr< T > set ( const label  i,
autoPtr< T > &&  ptr 
)
inline

Set element to given autoPtr and return old element.

Definition at line 213 of file PtrListI.H.

◆ set() [5/7]

Foam::autoPtr< T > set ( const label  i,
std::unique_ptr< T > &&  ptr 
)
inline

Set element to given unique_ptr and return old element.

Definition at line 224 of file PtrListI.H.

◆ set() [6/7]

Foam::autoPtr< T > set ( const label  i,
const refPtr< T > &  ptr 
)
inline

Set element to given refPtr and return old element.

Definition at line 235 of file PtrListI.H.

References refPtr< T >::ptr().

Here is the call graph for this function:

◆ set() [7/7]

Foam::autoPtr< T > set ( const label  i,
const tmp< T > &  ptr 
)
inline

Set element to given tmp and return old element.

Definition at line 246 of file PtrListI.H.

References tmp< T >::ptr().

Here is the call graph for this function:

◆ release()

Foam::autoPtr< T > release ( const label  i)
inline

Release ownership of the pointer at the given position.

Out of bounds addressing is a no-op and returns nullptr.

Definition at line 257 of file PtrListI.H.

◆ transfer()

void transfer ( PtrList< T > &  list)
inline

Transfer into this list and annul the argument list.

Definition at line 269 of file PtrListI.H.

References kinematicSingleLayer::transfer().

Referenced by faMesh::addFaPatches(), wallDistData< TransferType >::correct(), meshWave::correct(), directionalMeshWave::correct(), IATE::read(), and CompactListList< T >::transfer().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator=() [1/2]

void operator= ( const PtrList< T > &  list)

Copy assignment.

For existing list entries, values are copied from the list. For new list entries, pointers are cloned from the list.

Definition at line 133 of file PtrList.C.

References resize(), and UPtrList< T >::size().

Referenced by IOPtrList< Foam::entry >::operator=(), IOPtrList< T >::operator=(), and PtrDynList< T, SizeMin >::operator=().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator=() [2/2]

void operator= ( PtrList< T > &&  list)
inline

Move assignment.

Definition at line 279 of file PtrListI.H.

◆ clone() [2/2]

Foam::PtrList< T > clone ( Args &&...  args) const

Definition at line 82 of file PtrList.C.

References args, UPtrList< T >::ptrs_, and T.

◆ emplace() [2/2]

Foam::autoPtr< T > emplace ( const label  i,
Args &&...  args 
)
inline

Definition at line 180 of file PtrListI.H.

Friends And Related Function Documentation

◆ operator>>

Istream & operator>> ( Istream is,
PtrList< T > &  list 
)
friend

Read from Istream, discarding contents of existing list.


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