About Jolt.NET Libraries

Inspired by the Boost C++ libraries, Jolt.NET aims to complement the .NET Base Class Library (BCL) with algorithms, data structures, and general productivity tools. It is the hope of the authors that the features of Jolt.NET will one day be part of, or represented in the BCL and the .NET Framework.

More on XML Documentation Comments

I recently posted about some of the challenges involved with implementing an algorithm that will locate an XML doc comment file, given a reference to a System.Reflection.Assembly object.  Today, I would like to discuss the extent of how this feature will be used and exposed in the Jolt library.

Initially, I had planned to keep the XML doc comment parsing internal and expose it as a feature of the ProxyTypeBuilder class.  As described in work item #95, copying existing XML doc comments to those of the generated interface and proxy type will provide richer Intellisense.  However, while designing the classes that implement this feature, I noticed that they would be better suited as public types as they may be used to solve many XML doc comment parsing tasks.  Consequently, the following use cases will be supported.

  • Inferring the location of an XML doc comment file from a reference to a System.Reflection.Assembly object.
  • Obtaining the XML doc comments for a given metadata type (i.e. System.Type, System.Reflection.MethodInfo, System.Reflection.ConstructorInfo, etc…).
  • Converting a given metadata type into its XML doc comment string representation.

The code example in the previous post on this topic gives the syntax example for the first two bullets.  The conversion task allows one to take a MethodInfo type for a method such as void Namespace.MyType.MyMethod<U>(out T t, U u[]) and turn it into the string “M:Namespace.MyType`0.MyMethod(`0,``0[])”, which is the key into the XML doc comment data for the corresponding method.

If you search the web for articles relating to reading or parsing an XML doc comment file, you will see many requests for knowledge on how to transform a .NET metadata type into the corresponding XML documentation.  The proposed XmlDocCommentReader class will make this very easy to do.  The conversion functions are geared more towards lower-level development, and they may be used to support the implementation of an XSLT or various XPath queries.

These features are currently under development and will be ready within a few days (of development time).  Currently, I’m focusing on the testing of all of the possible permutations of generic/array/pointer/ref types that change the resulting key into the XML doc comment member list.  There are plenty of permutations, and a lot more than I had initially expected!


Anonymous said...

can you write something about proxy and vpn i'll be very happy

Steve Guidi said...

Hi there.

I'm not sure I understand your request. If you could provide an example, I'd be happy to look into it.