With Visual Studio 11 Beta, we had started sharing the code index SDK.

Last week, we shipped the Visual Studio 2012 RC Visualization and modeling SDK (VsVmSDK RC), which, among other features, contains the Code index SDK build tasks. This is an opportunity to explain what changed in the Code Index SDK.

Modifications to the bulk indexing

  • We have made a few modifications in the bulk indexing. I have updated the previous reference post The Code Index SDK – Part 2 – Bulk indexing assemblies into the code index to explain the details of the changes (changes highlighted, and differences from beta explained in purple).
  • We have now added a code index loader for the PDB files. This means that, if you have generated your assemblies with the PDB files (containing the debug symbols), and if you bulk index them, the information about source files and line numbers will be available in the code index for methods and method calls. Note that this information is not used by the Dependency diagrams in Visual Studio 2012 Ultimate, and therefore, the PDB are not loaded if you index solutions from Visual Studio (using the Architecture | Generate dependency files | for solution). This only works with Bulk indexing. To benefit this feature, you’ll need to use the build tasks provided with the VsVm SDK.

Update of the samples

We have updated the first 2 samples, to account for a few schema changes (for details, see What is new in Visual Studio 2012 RC Visualization and Modeling SDK). The sample named Code Index - How to discover ignored tests can now display the source and line of the offending tests, if the index was bulk loaded.

Finally, we have added a new sample which produces a file containing the public API of indexed assemblies. (See Code Index - How to discover and output the public API of an assembly) This useful, for instance, if you provide an assembly to your customers, and want to make sure that you won’t provoke any breaking change, or just to document the changes. To do that, you would index a previous version of your assembly, and dump its public API using the sample, then index the new version of the assembly and dump its public API as well, and then diff the 2 resulting text files. This is also useful if you leverage third party assemblies and want to check if you will be broken or plan work to do. Technically, this sample is also great in the sense that it shares a bit more of the code index schema, in particular it show how to browse through the notion of Type Signatures, and method signatures.

Conclusion

If you want to try out the new code index SDK: