You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
Still plenty of missing features: * Content-defined chunking * Caching * Hashing and deduplication of nodes through BlobWriter * Writing of aliases and refs through BlobWriter * HTTP client [CL 30022723 by ben marsh in ue5-main branch]
41 lines
781 B
C++
41 lines
781 B
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#include "Compute/ComputeChannel.h"
|
|
#include <string.h>
|
|
#include <stdio.h>
|
|
#include "Compute/ComputeSocket.h"
|
|
|
|
FComputeChannel::FComputeChannel()
|
|
{
|
|
}
|
|
|
|
FComputeChannel::FComputeChannel(FComputeBufferReader InReader, FComputeBufferWriter InWriter)
|
|
: Reader(MoveTemp(InReader))
|
|
, Writer(MoveTemp(InWriter))
|
|
{
|
|
}
|
|
|
|
FComputeChannel::~FComputeChannel()
|
|
{
|
|
}
|
|
|
|
bool FComputeChannel::IsValid() const
|
|
{
|
|
return Reader.IsValid();
|
|
}
|
|
|
|
size_t FComputeChannel::Send(const void* Data, size_t Size, int TimeoutMs)
|
|
{
|
|
return Writer.Write(Data, Size, TimeoutMs);
|
|
}
|
|
|
|
size_t FComputeChannel::Recv(void* Data, size_t Size, int TimeoutMs)
|
|
{
|
|
return Reader.Read(Data, Size, TimeoutMs);
|
|
}
|
|
|
|
void FComputeChannel::MarkComplete()
|
|
{
|
|
Writer.MarkComplete();
|
|
}
|