[Mono-docs-list] Differences between generic names in the documentation.

Jonathan Pryor jonpryor at vt.edu
Mon Dec 10 14:04:22 EST 2007


On Mon, 2007-12-10 at 17:57 +0100, Valentin Sawadski wrote:
> By the way I think it should be pretty easy to extend monodocer to
> generate <TypeSignature /> and <MemberSignature /> tags for different
> languages. (Like MS does within their docs) This could probably be done
> by using Mono.Addins so that 3rd party language developers could also
> integrate their language to the docs. (Especially Boo, VB.NET and
> Nemerle)

This should currently be pretty trivial -- just create a subclass of
MemberFormatter for your particular language and call your new formatter
in "the appropriate places."  This could be done much easier, but the
fact that we currently already have an abstraction in place to generate
these signature strings helps immensely.

Using Mono.Addins is also an interesting idea, though I'm not sure how
useful it would be.  The reason being that <TypeSignature/> and
<MemberSignature/> are generated at `monodocer` runtime, and the system
that `monodocer` is run on may not have the plugins you desire.

What would make more sense -- though I have no idea how easy this would
be -- is to alter the docbrowser to use Mono.Addins and have an XML ->
signature addin for each language.  We'd likely need to extend the XML
syntax further -- we have a <TypeParameter/> element but it's only used
at class level, and it should likely be inserted at member level as well
for generic methods -- but this would allow users to install addins on
their local machine and have the XML signatures translated "on-the-fly"
to their desired language.

The downside is that the XML contains C#-formatted type names (see other
message for reasons why this won't change), so this effectively requires
a C# -> language translator as well in some circumstances, but for the
basics of member name, method parameters, type parameters, etc., this is
all readily extractable from the XML.

 - Jon




More information about the Mono-docs-list mailing list