You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
6553e6cd0a
#preflight 61eefc77ba69a4fdb220bf23 #ROBOMERGE-AUTHOR: marc.audy #ROBOMERGE-SOURCE: CL 18712765 in //UE5/Release-5.0/... via CL 18712784 via CL 18713147 #ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472) [CL 18713191 by marc audy in ue5-main branch]
60 lines
1.5 KiB
C++
60 lines
1.5 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#pragma once
|
|
|
|
#include "Containers/Array.h"
|
|
#include "Misc/Guid.h"
|
|
#include "Templates/SharedPointer.h"
|
|
#include "UObject/NameTypes.h"
|
|
|
|
class IMessageContext;
|
|
class IMessageTransportHandler;
|
|
|
|
|
|
/**
|
|
* Interface for message transport technologies.
|
|
*
|
|
* Licensees can implement this interface to add support for custom message transport
|
|
* technologies that are not supported out of the box, i.e. custom network protocols or APIs.
|
|
*/
|
|
class IMessageTransport
|
|
{
|
|
public:
|
|
|
|
/**
|
|
* Gets the name of this transport (for debugging purposes).
|
|
*
|
|
* @return The debug name.
|
|
*/
|
|
virtual FName GetDebugName() const = 0;
|
|
|
|
/**
|
|
* Starts up the message transport.
|
|
*
|
|
* @param Handler The handler of inbound transport messages and events.
|
|
* @return Whether the transport was started successfully.
|
|
* @see StopTransport
|
|
*/
|
|
virtual bool StartTransport(IMessageTransportHandler& Handler) = 0;
|
|
|
|
/**
|
|
* Shuts down the message transport.
|
|
*
|
|
* @see StartTransport
|
|
*/
|
|
virtual void StopTransport() = 0;
|
|
|
|
/**
|
|
* Transports the given message data to the specified network nodes.
|
|
*
|
|
* @param Context The context of the message to transport.
|
|
* @param Recipients The transport nodes to send the message to.
|
|
* @return true if the message is being transported, false otherwise.
|
|
*/
|
|
virtual bool TransportMessage(const TSharedRef<IMessageContext, ESPMode::ThreadSafe>& Context, const TArray<FGuid>& Recipients) = 0;
|
|
|
|
protected:
|
|
|
|
/** Virtual destructor. */
|
|
virtual ~IMessageTransport() { }
|
|
}; |