在Visual Studio(C#)中显示名称空间的类 [英] display classes of a namespace in visual studio (C#)

查看:61
本文介绍了在Visual Studio(C#)中显示名称空间的类的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Java程序员,刚开始使用Visual Studio进行C#编程.在诸如Eclipse之类的Java IDE中,如果我不知道包中的类名,则只需在包名后键入点(.),即可获得该包中所有类的列表.我如何配置Visual Studio以执行类似的操作,例如,如果单击文件中的名称空间名称(例如,使用System),或在名称空间后添加点,则该名称空间中的所有类都将显示在某处?

I am a Java programmer, and just starting to use Visual Studio to do C# programming. In Java IDE such as Eclipse, if I do not know the class name in a package, I can just type a dot (.) after a package name, then I will get a list of all the classes in that package. How I can configure visual studio to do the similar thing, say, if I click a namespace name in a file (for example, using System), or add a dot after the namespace, all the classes in that namespace will be displayed somewhere?

推荐答案

如果您想知道,请首先确保其他内容(例如IME)未使用Ctrl + SPACE.然后在编辑器中为IntelliSense执行此快捷方式.Visual Studio将显示您可以在上下文中访问的所有类.它可能无法像Java一样工作,但是像我这样的大多数人都发现它足以继续前进.

If you want to know, first make sure Ctrl + SPACE is not used by other things such as IME. Then execute this shortcut for IntelliSense within the editor. Visual Studio will display all classes you can access in the context. It may not work like Java, but most people like me find it enough to move on.

为了更好地理解每个名称空间,我更习惯在名称空间上按F1以启动MSDN.

To better understand each namespace, I am more used to hit F1 on the namespace to launch MSDN.

这篇关于在Visual Studio(C#)中显示名称空间的类的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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