Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Memory
References
| Module | Core |
| Header | /Engine/Source/Runtime/Core/Public/Memory/SharedBuffer.h |
| Include | #include "Memory/SharedBuffer.h" |
Syntax
class FSharedBuffer
Remarks
A reference to a shared-ownership immutable buffer.
Constructors
| Type | Name | Description | |
|---|---|---|---|
| Construct a null shared buffer. | |||
FSharedBuffer
(
FBufferOwner* Owner |
Construct a shared buffer from a new unreferenced buffer owner. |
Functions
| Type | Name | Description | |
|---|---|---|---|
| FSharedBuffer | Clone
(
FMemoryView View |
Make an owned clone of the input. | |
| FSharedBuffer | Clone
(
const void* Data, |
Make an owned clone of the input. | |
| const void * | GetData () |
Returns a pointer to the start of the buffer. | |
| uint64 | GetSize () |
Returns the size of the buffer in bytes. | |
| FMemoryView | GetView () |
Returns a view of the buffer. | |
| bool | Returns true if the referenced buffer has been materialized. | ||
| bool | IsNull () |
Returns true if this does not point to a buffer owner. | |
| bool | IsOwned () |
Returns true if this keeps the referenced buffer alive. | |
| FSharedBuffer | MakeOwned () |
||
| FSharedBuffer | MakeOwned () |
Returns a buffer that is owned, by cloning if not owned. | |
| FSharedBuffer | MakeView
(
const void* Data, |
Make a non-owned view of the input. | |
| FSharedBuffer | MakeView
(
const void* Data, |
Make a non-owned view of the input. | |
| FSharedBuffer | MakeView
(
FMemoryView View, |
Make a non-owned view of the input. | |
| FSharedBuffer | MakeView
(
FMemoryView View |
Make a non-owned view of the input. | |
| FSharedBuffer | MakeView
(
const void* Data, |
Make a non-owned view of the input. | |
| FSharedBuffer | MakeView
(
FMemoryView View, |
Make a view of the input within its outer buffer. Ownership matches OuterBuffer. | |
| void | Materialize () |
Materialize the buffer by making its data and size available. | |
| FUniqueBuffer | MoveToUnique () |
Convert this to a unique buffer, leaving this null. | |
| void | Reset () |
Reset this to null. | |
| FSharedBuffer | TakeOwnership
(
const void* Data, |
Make an owned buffer by taking ownership of the input. | |
| FSharedBuffer | TakeOwnership
(
const void* Data, |
Make an owned buffer by taking ownership of the input. |
Operators
| Type | Name | Description | |
|---|---|---|---|
| Returns true if this points to a buffer owner. | |||
| bool | operator!=
(
const FSharedBuffer& BufferB |
||
| bool | operator==
(
const FSharedBuffer& BufferB |
Typedefs
| Name | Description |
|---|---|
| FOwnerPtrType | |
| FWeakOwnerPtrType |