vs插件开发

来源:互联网 发布:淘宝网店怎么开大概要多少钱 编辑:程序博客网 时间:2024/05/18 00:21

The Visual Studio integrated development environment (IDE) is a framework for hosting VSPackages and for making it easier to exchange shared services. An example of this is the way the IDE implements the user interface (UI). The IDE provides the container window and the default toolbars and menus. It also provides a rich COM infrastructure that makes the UI programmable. The complete command handling and routing scheme gives users an open framework that offers easy access to both existing and installed command sets.

Extensibility Architecture

The following illustration shows the Visual Studio extensibility architecture. Note that the concept of software application is absent. Instead, the IDE hosts software components, called VSPackages, that provide application functionality. This functionality, in turn, is shared across the IDE as services. VSPackages offer services that they and other VSPackages use. The standard IDE also offers a broad range of services, such as SVsUIShell, which provide access to the IDE windowing functionality.

Generalized view of the Visual Studio architecture

Environment Architecture graphic

Notice that the relationship between VSPackages and services is bidirectional. Although VSPackages use services offered by others, they also can offer services of their own by using the IProfferService interface. This service-based architecture grew out of the Microsoft ActiveX Designer implementation, in which a service is a group of related interfaces that perform a task. From a strict COM viewpoint, all the interfaces of a particular service must be implemented in a single COM class.

The standard IDE offers important services, such as SVsShell, SVsUIShell, and SVsSolution, which are used by VSPackages. The following table lists and describes some of these services. For more information, see Services.

IDE service

Description

SVsShell

Provides access to IDE services dealing with basic functionality, VSPackages, and the registry.

SVsUIShell

Provides basic windowing and UI-related functionality in the IDE, such as the ability to create tools and document windows.

SVsSolution

Provides basic solution-related functionality, such as the ability to enumerate projects, create new projects, and monitor project changes.

Because of their tight integration through the interaction of shared services, the Visual Studio IDE and VSPackages are closely interdependent. However, despite their close interaction they have different responsibilities.

The Visual Studio IDE is responsible for the following tasks:

  • Providing critical services for use by external VSPackages.

  • Providing a programmable interface, which enables participation with standard UI elements.

  • Creating instances of VSPackages as required by user actions or by other VSPackages requesting services.

  • Providing services that make it possible for communication and coordination between VSPackages.

  • Managing solutions and their required files.

  • Providing window management.

  • Providing command routing and command bars, such as menus, toolbars, and context menus.

  • Coordinating selection, context, and currency.

VSPackages are responsible for the following tasks:

  • Performing certain initialization and termination routines.

  • Writing information to the registry, which the IDE uses to load the appropriate VSPackages at the appropriate times.

  • Offering the services that are required for communicating with other VSPackages.

  • Providing implementations for new project types, editors, and designers.

  • Providing extensions for built-in UI elements, such as task items, toolbox items, and the Options dialog box.

0 0
热门问题 老师的惩罚 人脸识别 我在镇武司摸鱼那些年 重生之率土为王 我在大康的咸鱼生活 盘龙之生命进化 天生仙种 凡人之先天五行 春回大明朝 姑娘不必设防,我是瞎子 3岁宝宝一直吐怎么办 5个月宝宝一直吐怎么办 新生儿睡反了觉怎么办 吃母乳奶流量大怎么办 两个月宝宝有痰怎么办 婴儿瞌睡睡倒了怎么办 侧切伤口崩开了怎么办 脐带30天未脱落怎么办 洗眉结痂不掉怎么办 新生宝宝生殖器下面破皮怎么办 脐带未脱落渗血怎么办 车停店门口贴发单怎么办 有人要打我我该怎么办 很笨怎么办工作做不好 脸被电焊烤了疼怎么办 脸过敏痒的不行怎么办 领导想让你辞职怎么办 领导强吻我了怎么办 赫曼夏天温度高怎么办 近视看3d电影怎么办 有声挂图撕坏了怎么办 主机没有放光盘的设备怎么办 装显卡是没光驱怎么办 电脑机箱光盘总是出来怎么办 看书网作者密码忘记怎么办 电脑光驱访问出现出错怎么办 电脑不读dvd光盘怎么办 dvd光盘读不出来怎么办 光盘插在电脑里出不来怎么办 cad画斜线不光滑怎么办 ps没有魔棒工具怎么办 洗完鞋子发黄了怎么办 牛拜单车不退押金怎么办 总裁太爱我怎么办小说 小班走丢了怎么办ppt 走丢了怎么办 教案 ppt 小鸽子一大一小怎么办 烤八寸蛋糕胚表面上色严重怎么办 小班安全教案下雨打雷怎么办 幼儿园小班社会教案下雨打雷怎么办 两个月宝宝吃手怎么办