26 lines
1021 B
C++
26 lines
1021 B
C++
|
/***
|
||
|
Copyright (C) 2022 J Reece Wilson (a/k/a "Reece"). All rights reserved.
|
||
|
|
||
|
File: AuNetSrvResolve.hpp
|
||
|
Date: 2022-8-16
|
||
|
Author: Reece
|
||
|
***/
|
||
|
#pragma once
|
||
|
|
||
|
namespace Aurora::IO::Net
|
||
|
{
|
||
|
struct NetInterface;
|
||
|
struct NetSrvResolve : INetSrvResolve
|
||
|
{
|
||
|
NetSrvResolve(NetInterface *pParent);
|
||
|
|
||
|
virtual AuSPtr<IResolver> SimpleAResolve(const AuString &hostname, const AuSPtr<AuAsync::PromiseCallback<AuList<IPAddress>, NetError>> &info) override;
|
||
|
virtual AuSPtr<IResolver> SimpleAAAAResolve(const AuString &hostname, const AuSPtr<AuAsync::PromiseCallback<AuList<IPAddress>, NetError>> &info) override;
|
||
|
virtual AuSPtr<IResolver> SimpleAllResolve(const AuString &hostname, const AuSPtr<AuAsync::PromiseCallback<AuList<IPAddress>, NetError>> &info) override;
|
||
|
|
||
|
private:
|
||
|
AuSPtr<IResolver> SimpleResolve(const AuString &hostname, bool ipv4, bool ipv6, const AuSPtr<AuAsync::PromiseCallback<AuList<IPAddress>, NetError>> &info);
|
||
|
|
||
|
NetInterface *pParent_;
|
||
|
};
|
||
|
}
|