c++ - 列出 Win32 设备命名空间的内容

标签 c++ windows winapi namespaces device

来自微软独库:

The "\\.\" prefix will access the Win32 device namespace instead of the Win32 file namespace. This is how access to physical disks and volumes is accomplished directly, without going through the file system, if the API supports this type of access. You can access many devices other than disks this way (using the CreateFile and DefineDosDevice functions, for example).

For example, if you want to open the system's serial communications port 1, you can use "COM1" in the call to the CreateFile function. This works because COM1–COM9 are part of the reserved names in the NT namespace, although using the "\\.\" prefix will also work with these device names.

我的问题是,这个命名空间中有什么可用。是否有设备列表,我在哪里可以得到它? (我想我没理解这个话题。当我听到设备时,我想到目录中的某种文件。)

编辑:

好的,我会回答我自己的问题。有一个叫WinObj的软件,用它可以看到信息。

最佳答案

好的,我会回答我自己的问题。有一个叫WinObj的软件,用它可以看到信息。

关于c++ - 列出 Win32 设备命名空间的内容,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36199097/

相关文章:

c# - 获取USB设备的产品字符串(C#/C++)

c++ - 您可以使用 auto 在 namespace 范围内定义类静态常量吗?

c++ - 一个关于在 C++ 中转换整数的简单问题

android - 解析服务器仪表板不工作窗口

ruby-on-rails - Gem::Ext::BuildError:错误:无法构建 gem native 扩展。对于 SQlite3

C++ 和 GetAsyncKeyState() 函数

c++ - 没有在类 'void TestSub::print()' 中声明的 'TestSub' 成员函数

c++ - 尝试在 Visual Studio 2013 中使用 sqlite3_open 进行编译时出错

c++ - 是否有任何 C++ 库可以从 Windows 文件夹中的 thumb.db 读取缩略图?

winapi - 我可以从另一个进程卸载 DLL 吗? (Win32)