30 lines
765 B
C++
30 lines
765 B
C++
|
/***
|
||
|
Copyright (C) 2023 J Reece Wilson (a/k/a "Reece"). All rights reserved.
|
||
|
|
||
|
File: FSOverlappedUtilities.hpp
|
||
|
Date: 2023-1-26
|
||
|
Author: Reece
|
||
|
***/
|
||
|
#pragma once
|
||
|
|
||
|
namespace Aurora::IO::FS
|
||
|
{
|
||
|
struct BaseOverlappedOperation : virtual IOverlappedOperationBase
|
||
|
{
|
||
|
BaseOverlappedOperation();
|
||
|
|
||
|
virtual AuSPtr<Loop::ILoopSource> ToWaitable() override;
|
||
|
|
||
|
virtual AuSPtr<IOverlappedCallback> SetCallback(AuSPtr<IOverlappedOperationBase> pCallback) override;
|
||
|
|
||
|
virtual bool IsOperationComplete() override;
|
||
|
virtual bool IsOperationSuccessful() override;
|
||
|
|
||
|
void Complete();
|
||
|
void Fail();
|
||
|
|
||
|
private:
|
||
|
AuSPtr<Loop::ILoopSource> pWaitable;
|
||
|
AuSPtr<IOverlappedOperationBase> pCallback;
|
||
|
};
|
||
|
}
|