O'Reilly logo

Microsoft Visual Studio 2015 Unleashed, Third Edition by Mike Snell, Lars Powers

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Structure of an Extension

As we’ve seen, the VSIX extension project is composed of a few different files, all paved down by adding an extensibility project item. The core package class file contains the logic for our package.

Because packages are dynamic link libraries (DLLs), VSIX projects are class library projects. The core code file that is created implements a class called Microsoft.VisualStudio.Shell.Package. This class contains all the necessary interfaces to make the package work within the context of the IDE.

Referring back to our "Hello, World" example of a custom command, Listing 15.1 shows the core Package class as it was generated by the custom command project item template.

LISTING 15.1 Package Code Generated by the Custom ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required