XML comments for FieldIndex members

Posts   
 
    
Posts: 20
Joined: 02-Apr-2004
# Posted on: 04-May-2004 01:19:22   

When I build a generated C# project with the option to output an XML documentation file, the build succeeds, but I get a warning message of the following type for each member of each FieldIndex enum in ConstantsEnums.cs:

Missing XML comment for publicly visible type or member 'project.tableFieldIndex.field'

This is understandable. As it stands, LLBLGen Pro has no way of providing a meaningful comment that would be unique to each FieldIndex enum member. But it could have. I would like to see an enhancement to LLBLGen Pro whereby there would be a way for the user to provide a meaningful description for each column of each table. Where provided, these could then be used to generate XML comments for the corresponding FieldIndex enum members.

There is more than one way in which the field descriptions could be provided. One option would be to use the column description extended property that comes with SQL Server 2000. I do not know how widely used that feature is in data dictionary tools. I use a home-made data dictionary tool that I could quite easily enhance to output column descriptions to SQL Server's column description property.

Of course, I realise that I could also develop a way of generating the FieldIndex enum member XML comments from my data dictionary.

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39614
Joined: 17-Aug-2003
# Posted on: 04-May-2004 09:57:01   

Already in progress! simple_smile http://www.llblgen.com/tinyforum/Messages.aspx?ThreadID=730#3494

I didn't think of adding the custom properties to the XML comments, thanks for the tip!

Frans Bouma | Lead developer LLBLGen Pro
Posts: 20
Joined: 02-Apr-2004
# Posted on: 05-May-2004 03:50:03   

Custom properties? The thread that you reference above says:

  • custom properties (name-value pairs for custom values) for table/view/field/entity/field.

Let me see if I have understood this. Does that mean that I will be able to define a Description custom property for entity fields and then input Description text for each entity field via the GUI? And that this, and possibly other custom properties, could be used to populate the XML for FieldIndex members?

If so, that, in itself would not be quite enough. I, and no doubt many others, already have descriptions of fields in a data dictionary. There are a lot of them, and I would not want to have to copy and paste each one individually into the LLBLGEN Pro GUI. To get round this, you would need to provide some way of **_ importing_** the descriptions into the LLBLGEN Pro project.

That is why I suggested importing SQL Server's column description extended property. That is not the only or, come to think of it, necessarily the best way of doing it. Importing a CSV file would work too: e.g.

entity,field,description

Or one of those new-fangled XML files (perhaps overkill for this purpose).

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39614
Joined: 17-Aug-2003
# Posted on: 05-May-2004 08:42:47   

They are imported from the extended properties or description fields in the database simple_smile One of the screenshots shows the custom properties listed in the catalog explorer, and another screenshot shows the entity mapped on that table, with 2 of the custom properties the same ones as enlisted in the catalog explorer and 2 new simple_smile

Frans Bouma | Lead developer LLBLGen Pro
Posts: 20
Joined: 02-Apr-2004
# Posted on: 05-May-2004 22:51:05   

Excellent! simple_smile

Other possible XML uses:

  • Field property of entity. The description, (if non-blank!), would look good in the summary tag in place of what you currently show.
  • Field parameter of method, such as FetchUsingPK. I am not so sure about that one, as the information you currently provide in the param tag is already helpful. Perhaps the description could be appended to or in some other way combined with what you already have.
  • Entities. Here again, the information you currently provide in the summary tag is already helpful. Perhaps the table description could go in the remarks tag, which you do no currently generate for entities.
Posts: 20
Joined: 02-Apr-2004
# Posted on: 24-Dec-2004 00:03:10   

This is the first chance I have had to check out the new custom properties feature. I am using v1.0.2004.1. I can see that the Description custom property (and no doubt others if I had them) is being added to the XML summary of the property generated for each field in the EntityBase class generated for each table. This is great. Thanks.

But an equally important part of the addition of custom properties has not been done, the one I requested at the start of this thread. When I build a generated C# project with the option to output an XML documentation file, I am still getting dozens of warning messages of the following type:

Missing XML comment for publicly visible type or member 'project.tableFieldIndex.field'

One for message is shown for each member of each FieldIndex enum in ConstantsEnums.cs.

I had hoped that XML comments were going to be generated from the field custom properties corresponding to each FieldIndex enum member. And I still hope that this will eventually be done.

Of course I understand that, from the point of view of generating documentation, it was more important to add the custom properties to the EntityBase field properties. But it would be great not to have to see all those warning messages.

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39614
Joined: 17-Aug-2003
# Posted on: 24-Dec-2004 10:43:03   

The enum xml tags were omitted because it would increase a large project too much in size.

Frans Bouma | Lead developer LLBLGen Pro
Posts: 20
Joined: 02-Apr-2004
# Posted on: 30-Dec-2004 19:41:19   

Fair enough. I would rather see any little XML entry, not necessarily derived from the custom properties, to stop the compiler warnings. But it is a rather minor issue.