A class responsible for deserializing data from a memory buffer.
More...
#include <DeSerializerObject.h>
A class responsible for deserializing data from a memory buffer.
This class provides various functions to read different data types from a memory buffer.
◆ UDeSerializerObject()
UDeSerializerObject::UDeSerializerObject |
( |
| ) |
|
◆ Clear()
virtual void UDeSerializerObject::Clear |
( |
| ) |
|
|
virtual |
Clears the current deserialization state.
- Note
- This function resets the memory reader and any deserialized data.
◆ GetMemoryReaderRef()
FMemoryReader & UDeSerializerObject::GetMemoryReaderRef |
( |
| ) |
const |
|
protected |
Gets a reference to the memory reader.
- Returns
- A reference to the FMemoryReader instance.
◆ Start()
virtual void UDeSerializerObject::Start |
( |
const TArray< uint8 > & | InBytes | ) |
|
|
virtual |
Starts the deserialization process with the provided byte array.
- Parameters
-
InBytes | The array of bytes to deserialize. |
◆ TryReadBool()
virtual bool UDeSerializerObject::TryReadBool |
( |
bool & | OutBool | ) |
|
|
virtual |
Tries to read a boolean value from the buffer.
- Parameters
-
OutBool | Reference to the boolean variable where the read value will be stored. |
- Returns
- true if the boolean value was successfully read; false otherwise.
◆ TryReadDouble()
virtual bool UDeSerializerObject::TryReadDouble |
( |
double & | OutDouble | ) |
|
|
virtual |
Tries to read a double value from the buffer.
- Parameters
-
OutDouble | Reference to the double variable where the read value will be stored. |
- Returns
- true if the double value was successfully read; false otherwise.
◆ TryReadFloat()
virtual bool UDeSerializerObject::TryReadFloat |
( |
float & | OutFloat | ) |
|
|
virtual |
Tries to read a float value from the buffer.
- Parameters
-
OutFloat | Reference to the float variable where the read value will be stored. |
- Returns
- true if the float value was successfully read; false otherwise.
◆ TryReadInt()
virtual bool UDeSerializerObject::TryReadInt |
( |
int32 & | OutInt | ) |
|
|
virtual |
Tries to read an int32 value from the buffer.
- Parameters
-
OutInt | Reference to the int32 variable where the read value will be stored. |
- Returns
- true if the int32 value was successfully read; false otherwise.
◆ TryReadInt64()
virtual bool UDeSerializerObject::TryReadInt64 |
( |
int64 & | OutInt64 | ) |
|
|
virtual |
Tries to read an int64 value from the buffer.
- Parameters
-
OutInt64 | Reference to the int64 variable where the read value will be stored. |
- Returns
- true if the int64 value was successfully read; false otherwise.
◆ TryReadIntPoint()
virtual bool UDeSerializerObject::TryReadIntPoint |
( |
FIntPoint & | OutIntPoint | ) |
|
|
virtual |
Tries to read an FIntPoint value from the buffer.
- Parameters
-
OutIntPoint | Reference to the FIntPoint variable where the read value will be stored. |
- Returns
- true if the FIntPoint value was successfully read; false otherwise.
◆ TryReadIntVector()
virtual bool UDeSerializerObject::TryReadIntVector |
( |
FIntVector & | OutIntVector | ) |
|
|
virtual |
Tries to read an FIntVector value from the buffer.
- Parameters
-
OutIntVector | Reference to the FIntVector variable where the read value will be stored. |
- Returns
- true if the FIntVector value was successfully read; false otherwise.
◆ TryReadObject()
virtual bool UDeSerializerObject::TryReadObject |
( |
UObject * | InObjectOuter, |
|
|
UObject *& | OutObject ) |
|
virtual |
Tries to read an UObject value from the buffer.
- Parameters
-
InObjectOuter | Object owner (must be valid) |
OutObject | UObject* variable where the read value will be stored. |
- Returns
- true if the UObject* value was successfully read; false otherwise.
◆ TryReadObjects()
virtual bool UDeSerializerObject::TryReadObjects |
( |
UObject * | InObjectOuter, |
|
|
TArray< UObject * > & | OutObjects ) |
|
virtual |
Tries to read an array of UObjects from the buffer.
- Parameters
-
InObjectOuter | Object owner (must be valid) |
OutObjects | Array variable where the read value will be stored. |
- Returns
- true if the TArray<UObject*> value was successfully read; false otherwise.
◆ TryReadRotator()
virtual bool UDeSerializerObject::TryReadRotator |
( |
FRotator & | OutRotator | ) |
|
|
virtual |
Tries to read an FRotator value from the buffer.
- Parameters
-
OutRotator | Reference to the FRotator variable where the read value will be stored. |
- Returns
- true if the FRotator value was successfully read; false otherwise.
◆ TryReadString()
virtual bool UDeSerializerObject::TryReadString |
( |
FString & | OutString | ) |
|
|
virtual |
Tries to read an FString value from the buffer.
- Parameters
-
OutString | Reference to the FString variable where the read value will be stored. |
- Returns
- true if the FString value was successfully read; false otherwise.
◆ TryReadT()
template<typename T >
bool UDeSerializerObject::TryReadT |
( |
T & | OutValue | ) |
|
|
inline |
Attempts to read a value of type T from the memory buffer.
- Template Parameters
-
T | The type of the value to read. |
- Parameters
-
OutValue | Reference to the variable where the read value will be stored. |
- Returns
- true if the value was successfully read; false otherwise.
◆ TryReadTransform()
virtual bool UDeSerializerObject::TryReadTransform |
( |
FTransform & | OutTransform | ) |
|
|
virtual |
Tries to read an FTransform value from the buffer.
- Parameters
-
OutTransform | Reference to the FTransform variable where the read value will be stored. |
- Returns
- true if the FTransform value was successfully read; false otherwise.
◆ TryReadUInt8()
virtual bool UDeSerializerObject::TryReadUInt8 |
( |
uint8 & | OutUInt8 | ) |
|
|
virtual |
Tries to read a uint8 value from the buffer.
- Parameters
-
OutUInt8 | Reference to the uint8 variable where the read value will be stored. |
- Returns
- true if the uint8 value was successfully read; false otherwise.
◆ TryReadVector()
virtual bool UDeSerializerObject::TryReadVector |
( |
FVector & | OutVector | ) |
|
|
virtual |
Tries to read an FVector value from the buffer.
- Parameters
-
OutVector | Reference to the FVector variable where the read value will be stored. |
- Returns
- true if the FVector value was successfully read; false otherwise.
◆ TryReadVector2D()
virtual bool UDeSerializerObject::TryReadVector2D |
( |
FVector2D & | OutVector2D | ) |
|
|
virtual |
Tries to read an FVector2D value from the buffer.
- Parameters
-
OutVector2D | Reference to the FVector2D variable where the read value will be stored. |
- Returns
- true if the FVector2D value was successfully read; false otherwise.
◆ MemoryReader
TSharedPtr<FMemoryReader> UDeSerializerObject::MemoryReader |
|
protected |
Memory reader used to deserialize data from a buffer.
The documentation for this class was generated from the following file: