HttpDnsService *httpdns= [[HttpDnsService alloc] autoInit];
[httpdns setCachedIPEnabled:YES];
[httpdns enableIPv6:YES];
[httpdns setRegion:@"hk"];
[httpdns setPreResolveHosts:@[@"www.taobao.com", @"www.aliyun.com"] queryIPType:AlicloudHttpDNS_IPTypeV64];
[httpdns setPreResolveAfterNetworkChanged:YES];
[httpdns setSdnsGlobalParams:@{@"tag": @"vip"}];
NSString *ip_ipv6 = [httpdns getIPv6ByHostAsync:@"www.aliyun.com"];
NSDictionary *ipsDic = [httpdns getIPv4_v6ByHostAsync:@"www.aliyun.com"];
购物车
你好,我是AI助理
可以解答问题、推荐解决方案等