MCRO
C++23 utilities for Unreal Engine.
Loading...
Searching...
No Matches
Mcro::SharedObjects::TSharedStorage< T > Struct Template Reference

A simple mutable shared storage of any value. More...

#include <SharedObjects.h>

Data Fields

Value
 

Detailed Description

template<CDefaultInitializable T>
struct Mcro::SharedObjects::TSharedStorage< T >

A simple mutable shared storage of any value.

One particular use case for this may be delegates which may remove themselves once invoked. For example:

once->Value = MyEvent.AddLambda([this, once]
{
// execute something only once.
MyEvent.Remove(once->Value);
});
FORCEINLINE TSharedStorageRef< FDelegateHandle > MakeSharedDelegateHandle()
A simple convenience wrapper around making FDelegateHandles shared.

Definition at line 189 of file SharedObjects.h.

Field Documentation

◆ Value

template<CDefaultInitializable T>
T Mcro::SharedObjects::TSharedStorage< T >::Value

Definition at line 191 of file SharedObjects.h.


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