UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
GenericPlatformNamedPipe.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
6#include "CoreTypes.h"
7
8#if PLATFORM_SUPPORTS_NAMED_PIPES
9
14{
15public:
16
19
22
24 FGenericPlatformNamedPipe& operator=(const FGenericPlatformNamedPipe&) = delete;
25
26public:
27
29 virtual bool Create(const FString& PipeName, bool bServer, bool bAsync) { return false; }
30
32 virtual const FString& GetName() const
33 {
34 return *NamePtr;
35 }
36
38 virtual bool Destroy() { return false; }
39
41 virtual bool OpenConnection() { return false; }
42
44 virtual bool BlockForAsyncIO() { return false; }
45
47 virtual bool IsReadyForRW() const { return false; }
48
50 virtual bool UpdateAsyncStatus() { return false; }
51
53 virtual bool WriteBytes(int32 NumBytes, const void* Data) { return false; }
54
56 inline bool WriteInt32(int32 In)
57 {
58 return WriteBytes(sizeof(int32), &In);
59 }
60
61 /* Read a buffer in. */
62 virtual bool ReadBytes(int32 NumBytes, void* OutData) { return false; }
63
65 inline bool ReadInt32(int32& Out)
66 {
67 return ReadBytes(sizeof(int32), &Out);
68 }
69
71 virtual bool IsCreated() const { return false; }
72
74 virtual bool HasFailed() const { return true; }
75
76protected:
77
78 FString* NamePtr;
79};
80
81
82#endif
FPlatformTypes::int32 int32
A 32-bit signed integer.
Definition Platform.h:1125
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
IMAGECORE_API const TCHAR * GetName(Type Format)
Definition ImageCore.cpp:1378
void WriteBytes(FNetBitStreamWriter *Writer, const uint8 *Src, uint32 BytesToWrite)
Definition NetBitStreamUtil.cpp:952
void ReadBytes(FNetBitStreamReader *Reader, uint8 *Destination, uint32 BytesToRead)
Definition NetBitStreamUtil.cpp:923