Home > Documentation, Templates > Generating Documentation

Generating Documentation

CodeFluent Entities provides a documentation sub-producer which allows you to:

  • Decorate all members with XML comments (usable by Visual Studio IntelliSense and help tools),
  • Generate XML, batch and configuration files to create a .CHM documentation using Sandcastle.

To benefit from it, you first need to add an instance of the sub-producer. To do so, select the Business Object Model Producer instance of your project, right-click on it and select “Add New SubProducer”. Then in the “Add New SubProducer” dialog, select “Documentation” in the tree view and configure it:


Note: the only required property is the “Sandcastle Target Directory “which needs to be specified so the producer knows where to generate its output files. If producing Sandcastle files, you need to have Sandcastle installed before generating and ensure the Sandcastle path is correct so you’ll be able to use the generated files right away.

Since decorating all members of all your generated classes all the time can be quite an overkill during developments, it is disabled by default in the Business Object Model producer, so you need to enable it as well. Double-click on your Business Object Model producer instance to open its configuration and set “Generate Xml Documentation” to “True”:


In the XML this looks like something like that:

<cf:producer typeName="CodeFluent.Producers.CodeDom.CodeDomProducer, CodeFluent.Producers.CodeDom">
  <cf:configuration targetDirectory="..\Sample" outputName="{0}.dll" generateDocumentation="true">
    <subProducer typeName="CodeFluent.Producers.Documentation.DocumentationProducer, CodeFluent.Producers.Documentation"
                 targetDirectory="..\Doc" sourceDirectory="%CF_TEMPLATES_PATH%\Documentation" />

Build over your project and you’ll see that all your members have XML remarks on them! Moreover, in the Sandcastle Target Directory you specified, you’ll see a set of files allowing you to generate a .CHM file documenting the generated objet model Smile

  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s