You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#jira UE-178144 #rb martin.ridgers #preflight 645117e41c2846595cac18ec [CL 25301376 by Johan Berg in ue5-main branch]
49 lines
1.0 KiB
C++
49 lines
1.0 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#pragma once
|
|
|
|
#include "Asio.h"
|
|
#include "AsioTcpServer.h"
|
|
#include "AsioTickable.h"
|
|
#include "Foundation.h"
|
|
|
|
class FStore;
|
|
class FRecorderRelay;
|
|
|
|
////////////////////////////////////////////////////////////////////////////////
|
|
class FRecorder
|
|
: public FAsioTcpServer
|
|
, public FAsioTickable
|
|
{
|
|
public:
|
|
class FSession
|
|
{
|
|
public:
|
|
uint32 GetId() const;
|
|
uint32 GetTraceId() const;
|
|
uint32 GetIpAddress() const;
|
|
uint32 GetControlPort() const;
|
|
const FGuid& GetSessionGuid() const;
|
|
const FGuid& GetTraceGuid() const;
|
|
|
|
private:
|
|
friend FRecorder;
|
|
FRecorderRelay* Relay;
|
|
uint32 Id;
|
|
};
|
|
|
|
FRecorder(asio::io_context& IoContext, FStore& InStore);
|
|
~FRecorder();
|
|
void Close();
|
|
uint32 GetSessionCount() const;
|
|
const FSession* GetSessionInfo(uint32 Index) const;
|
|
|
|
private:
|
|
virtual bool OnAccept(asio::ip::tcp::socket& Socket) override;
|
|
virtual void OnTick() override;
|
|
TArray<FSession> Sessions;
|
|
FStore& Store;
|
|
};
|
|
|
|
/* vim: set noexpandtab : */
|