libnx  v4.8.0
resolver.h
1 #pragma once
2 #include "../types.h"
3 
4 /// Fetches the last resolver Switch result code of the current thread.
5 Result resolverGetLastResult(void);
6 
7 /// Retrieves a handle used to cancel the next resolver command on the current thread.
8 u32 resolverGetCancelHandle(void);
9 
10 /// Retrieves whether service discovery is enabled for resolver commands on the current thread.
11 bool resolverGetEnableServiceDiscovery(void);
12 
13 /// [5.0.0+] Retrieves whether the DNS cache is used to resolve queries on the current thread (not implemented).
14 bool resolverGetEnableDnsCache(void);
15 
16 /// Enables or disables service discovery for the current thread.
17 void resolverSetEnableServiceDiscovery(bool enable);
18 
19 /// [5.0.0+] Enables or disables the usage of the DNS cache on the current thread (not implemented).
20 void resolverSetEnableDnsCache(bool enable);
21 
22 /// Cancels a previous resolver command (handle obtained with \ref resolverGetCancelHandle prior to calling the command).
23 Result resolverCancel(u32 handle);
24 
25 /// [5.0.0+] Removes a hostname from the DNS cache (not implemented).
26 Result resolverRemoveHostnameFromCache(const char* hostname);
27 
28 /// [5.0.0+] Removes an IP address from the DNS cache (not implemented).
29 Result resolverRemoveIpAddressFromCache(u32 ip);
u32 Result
Function error code result type.
Definition: types.h:44
uint32_t u32
32-bit unsigned integer.
Definition: types.h:21