UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
PropertyNetSerializerInfoRegistry.h File Reference
#include "Containers/Array.h"
#include "Iris/Serialization/NetSerializer.h"
#include "Iris/Serialization/NetSerializerDelegates.h"
#include "Templates/Casts.h"
#include "Templates/Tuple.h"
#include "UObject/NameTypes.h"
#include "UObject/UnrealType.h"

Go to the source code of this file.

Classes

struct  UE::Net::FPropertyNetSerializerInfo
 
class  UE::Net::FPropertyNetSerializerInfoRegistry
 
struct  UE::Net::TSimplePropertyNetSerializerInfo< T, ConfigType >
 
struct  UE::Net::FNamedStructPropertyNetSerializerInfo
 
struct  UE::Net::FLastResortPropertyNetSerializerInfo
 
struct  UE::Net::FNamedStructLastResortPropertyNetSerializerInfo
 

Namespaces

namespace  UE
 
namespace  UE::Net
 

Macros

#define UE_NET_IS_DECLARED_TYPE(Name)
 
#define UE_NET_DECLARE_NETSERIALIZER_INFO(NetSerializerInfo)   const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##NetSerializerInfo();
 
#define UE_NET_IMPLEMENT_NETSERIALIZER_INFO(NetSerializerInfo)   const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##NetSerializerInfo() { static NetSerializerInfo StaticInstance; return StaticInstance; };
 
#define UE_NET_IMPLEMENT_SIMPLE_NETSERIALIZER_INFO(PropertyType, SerializerName)   const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##PropertyType() { static UE::Net::TSimplePropertyNetSerializerInfo<PropertyType> StaticInstance(UE_NET_GET_SERIALIZER(SerializerName)); return StaticInstance; };
 
#define UE_NET_IMPLEMENT_NAMED_STRUCT_NETSERIALIZER_INFO(Name, SerializerName)   const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##Name() { static UE::Net::FNamedStructPropertyNetSerializerInfo StaticInstance(Name, UE_NET_GET_SERIALIZER(SerializerName)); return StaticInstance; };
 
#define UE_NET_IMPLEMENT_NAMED_STRUCT_NETSERIALIZER_WITH_CUSTOM_FRAGMENT_INFO(Name, SerializerName, CreateAndRegisterReplicationFragmentFunction)
 
#define UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_INFO(StructName)   const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##StructName() { static UE::Net::FNamedStructLastResortPropertyNetSerializerInfo StaticInstance(StructName); return StaticInstance; };
 
#define UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_INFO_WITH_SIZE_OVERRIDE(StructName, MaxBits)   const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##StructName() { static UE::Net::FNamedStructLastResortPropertyNetSerializerInfo StaticInstance(StructName, MaxBits); return StaticInstance; };
 
#define UE_NET_REGISTER_NETSERIALIZER_INFO(Name)   UE::Net::FPropertyNetSerializerInfoRegistry::Register(&GetPropertyNetSerializerInfo_##Name());
 
#define UE_NET_UNREGISTER_NETSERIALIZER_INFO(Name)   UE::Net::FPropertyNetSerializerInfoRegistry::Unregister(&GetPropertyNetSerializerInfo_##Name());
 
#define UE_NET_IMPLEMENT_NETSERIALIZER_REGISTRY_DELEGATES(Name)
 
#define UE_NET_IMPLEMENT_FORWARDING_NETSERIALIZER_AND_REGISTRY_DELEGATES(Name, SerializerName)
 
#define UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_AND_REGISTRY_DELEGATES(Name)
 
#define UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_AND_REGISTRY_DELEGATES_WITH_SIZE_OVERRIDE(Name, MaxBits)
 

Functions

template<typename StructName >
constexpr auto UE::Net::IsDeclaredType (StructName *) -> decltype(sizeof(StructName))
 
constexpr auto UE::Net::IsDeclaredType (void *)
 
void UE::Net::ValidateForwardingNetSerializerTraits (const FNetSerializer *Serializer, EReplicationStateTraits UsedReplicationStateTraits)
 

Macro Definition Documentation

◆ UE_NET_DECLARE_NETSERIALIZER_INFO

◆ UE_NET_IMPLEMENT_FORWARDING_NETSERIALIZER_AND_REGISTRY_DELEGATES

#define UE_NET_IMPLEMENT_FORWARDING_NETSERIALIZER_AND_REGISTRY_DELEGATES (   Name,
  SerializerName 
)
Value:
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
#define PREPROCESSOR_TO_STRING(Token)
Definition PreprocessorHelpers.h:103
Definition NameTypes.h:617

◆ UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_AND_REGISTRY_DELEGATES

#define UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_AND_REGISTRY_DELEGATES (   Name)

◆ UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_AND_REGISTRY_DELEGATES_WITH_SIZE_OVERRIDE

◆ UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_INFO

#define UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_INFO (   StructName)    const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##StructName() { static UE::Net::FNamedStructLastResortPropertyNetSerializerInfo StaticInstance(StructName); return StaticInstance; };

◆ UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_INFO_WITH_SIZE_OVERRIDE

#define UE_NET_IMPLEMENT_NAMED_STRUCT_LASTRESORT_NETSERIALIZER_INFO_WITH_SIZE_OVERRIDE (   StructName,
  MaxBits 
)    const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##StructName() { static UE::Net::FNamedStructLastResortPropertyNetSerializerInfo StaticInstance(StructName, MaxBits); return StaticInstance; };

◆ UE_NET_IMPLEMENT_NAMED_STRUCT_NETSERIALIZER_INFO

◆ UE_NET_IMPLEMENT_NAMED_STRUCT_NETSERIALIZER_WITH_CUSTOM_FRAGMENT_INFO

#define UE_NET_IMPLEMENT_NAMED_STRUCT_NETSERIALIZER_WITH_CUSTOM_FRAGMENT_INFO (   Name,
  SerializerName,
  CreateAndRegisterReplicationFragmentFunction 
)
Value:
{ \
StaticInstance.SetCreateAndRegisterReplicationFragmentFunction(CreateAndRegisterReplicationFragmentFunction); \
return StaticInstance; \
};
#define UE_NET_GET_SERIALIZER(SerializerName)
Definition NetSerializer.h:470
Definition PropertyNetSerializerInfoRegistry.h:128
Definition PropertyNetSerializerInfoRegistry.h:52

Force a struct to use a custom serializer and custom fragment. Use of custom fragments is highly discouraged as serialization order is modified, ending up after normal class properties. It probably requires additional memory allocations to create the fragment as well. Only use a last resort when all other options have been exhausted. It should never be required to use custom fragments except for very rare backward compatibility purposes. Ask the experts first to try to find a better solution.

◆ UE_NET_IMPLEMENT_NETSERIALIZER_INFO

◆ UE_NET_IMPLEMENT_NETSERIALIZER_REGISTRY_DELEGATES

#define UE_NET_IMPLEMENT_NETSERIALIZER_REGISTRY_DELEGATES (   Name)
Value:
struct F##Name##NetSerializerRegistryDelegates : protected UE::Net::FNetSerializerRegistryDelegates \
{ \
}; \
static F##Name##NetSerializerRegistryDelegates Name##NetSerializerRegistryDelegates;
#define UE_NET_UNREGISTER_NETSERIALIZER_INFO(Name)
Definition PropertyNetSerializerInfoRegistry.h:249
#define UE_NET_REGISTER_NETSERIALIZER_INFO(Name)
Definition PropertyNetSerializerInfoRegistry.h:244
Definition NetSerializerDelegates.h:19
virtual IRISCORE_API void OnPreFreezeNetSerializerRegistry()
Definition NetSerializerDelegates.cpp:42

◆ UE_NET_IMPLEMENT_SIMPLE_NETSERIALIZER_INFO

#define UE_NET_IMPLEMENT_SIMPLE_NETSERIALIZER_INFO (   PropertyType,
  SerializerName 
)    const UE::Net::FPropertyNetSerializerInfo& GetPropertyNetSerializerInfo_##PropertyType() { static UE::Net::TSimplePropertyNetSerializerInfo<PropertyType> StaticInstance(UE_NET_GET_SERIALIZER(SerializerName)); return StaticInstance; };

◆ UE_NET_IS_DECLARED_TYPE

#define UE_NET_IS_DECLARED_TYPE (   Name)
Value:
static_assert( \
UE::Net::IsDeclaredType((struct F##Name*)nullptr) || \
UE::Net::IsDeclaredType((struct U##Name*)nullptr) \
, "The UE type name '" #Name "' cannot be found. Make sure you have removed the 'F' or 'U' prefix from the type name.");

◆ UE_NET_REGISTER_NETSERIALIZER_INFO

◆ UE_NET_UNREGISTER_NETSERIALIZER_INFO