AuroraRuntime/Source/IO/Net/AuNetSrvInterfaces.hpp

28 lines
705 B
C++

/***
Copyright (C) 2022 J Reece Wilson (a/k/a "Reece"). All rights reserved.
File: AuNetSrvInterfaces.hpp
Date: 2022-11-14
Author: Reece
***/
#pragma once
namespace Aurora::IO::Net
{
struct NetSrvInterfaces : INetSrvInterfaces
{
const AuString & GetHostname() override;
void ResetAdapterCache() override;
AuList<AuSPtr<INetAdapter>> GetAdapters() override;
bool IsSupportedOnOS();
private:
void UpdateCache();
cstatic AuMutex gLock;
cstatic AuString gHostname;
cstatic bool bShouldUpdateCache { true };
cstatic AuList<AuSPtr<INetAdapter>> gAdapters;
};
}