Go to the documentation of this file.
72 mutable refType type_;
98 template<
class... Args>
106 template<
class U,
class... Args>
113 inline constexpr
tmpNrc() noexcept;
116 inline constexpr
tmpNrc(std::nullptr_t) noexcept;
119 inline explicit
tmpNrc(
T*
p) noexcept;
122 inline
tmpNrc(const
T& obj) noexcept;
143 inline
bool isTmp() const noexcept;
146 inline
bool empty() const noexcept;
150 inline
bool valid() const noexcept;
153 inline
bool movable() const noexcept;
162 inline
T*
get() noexcept;
165 inline const
T*
get() const noexcept;
170 inline const
T&
cref() const;
175 inline
T&
ref() const;
188 inline
T*
ptr() const;
192 inline
void clear() const noexcept;
196 inline
void reset() noexcept;
199 inline
void reset(
T*
p) noexcept;
205 inline
void cref(const
T& obj) noexcept;
215 inline const
T& operator()() const;
218 inline operator const
T&() const;
222 inline const
T* operator->() const;
226 inline
T* operator->();
229 explicit inline operator
bool() const noexcept;
233 inline
void operator=(
T*
p);
237 inline
void operator=(const
tmpNrc<
T>& t);
240 inline
void operator=(
tmpNrc<
T>&& other) noexcept;
243 inline operator
tmp<
T>();
250 void operator=(std::nullptr_t) = delete;
Foam::refCount::zero refCount
Null reference counter class.
A class for handling words, derived from Foam::string.
word typeName() const
Return type-name of the tmp, constructed from type-name of T.
A class for managing temporary objects.
void Swap(DynamicList< T, SizeMin1 > &a, DynamicList< T, SizeMin2 > &b)
void swap(tmpNrc< T > &other) noexcept
Swaps the managed object with other.
T element_type
Type of object being managed.
A class for managing temporary objects without reference counting.
T & constCast() const
Non-const dereference, even if the object is const.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
void clear() const noexcept
void reset() noexcept
Release ownership of managed temporary object.
static tmpNrc< T > New(Args &&... args)
Construct tmpNrc of T with forwarding arguments.
A non-counting (dummy) refCount.
static tmpNrc< T > NewFrom(Args &&... args)
Construct tmpNrc from derived type with forwarding arguments.
bool valid() const noexcept
bool movable() const noexcept
True if this is a non-null managed pointer with a unique ref-count.
T * pointer
Pointer to type of object being managed.
bool empty() const noexcept
True if this is a non-null managed pointer.
constexpr tmpNrc() noexcept
Construct with no managed pointer.
Foam::argList args(argc, argv)
bool isTmp() const noexcept
True if this is a managed pointer (not a const reference)
T * get() noexcept
Return pointer without nullptr checking.