AuroraRuntime/Include/Aurora/IO/IIOBufferedProcessor.hpp

23 lines
817 B
C++
Raw Normal View History

/***
Copyright (C) 2022 J Reece Wilson (a/k/a "Reece"). All rights reserved.
File: IIOBufferedProcessor.hpp
Date: 2022-6-6
Author: Reece
***/
#pragma once
namespace Aurora::IO
{
struct IIOBufferedProcessor
{
virtual AuUInt32 TryProcessBuffered() = 0;
virtual AuUInt32 GetRawBytesBuffered() = 0;
virtual AuUInt32 GetRawBytesLimit() = 0;
};
AUKN_SYM AuSPtr<IIOBufferedProcessor> NewBufferedProcessor(const AuSPtr<IStreamReader> &source,
const AuSPtr<IIOPipeInterceptor> &processor,
const AuSPtr<IStreamWriter> &drain, // TODO: share IOPipeCallback
AuUInt32 bufferSize);
}