在Android源$ C ​​$ C DNS查询 [英] DNS query in android source code

查看:124
本文介绍了在Android源$ C ​​$ C DNS查询的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人可以指出在Android源$ C ​​$ c,其中一个DNS查询所取得的code?

Can someone please point out the code in android source code, where a DNS query is being made?

我试图找到code,其中实际的DNS查询从应用程序发送的,但我不能。

I tried to locate the code where the actual DNS query is sent from an application, but i couldn't.

任何帮助将是巨大的。

在此先感谢

推荐答案

通常你不会做出明确的DNS查询Java编写的。

Normally you don't make an explicit DNS query in Java.

创建一个插座 你可以传递一个主机名和Java虚拟机得到OS代其执行DNS查询。这就是为什么你不需要为你的Java虚拟机配置DNS设置。

When you create a Socket you can pass a hostname and the Java VM gets the OS to perform the DNS query on its behalf. This is why you don't need to configure DNS settings for your Java VM.

有DNS的纯Java实现,但我不相信任何这些都与Android提供。

There are pure Java implementations of DNS, but I don't believe any of these are supplied with Android.

这篇关于在Android源$ C ​​$ C DNS查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆