Partial Classes, Flat TOC ?

Topics: User Forum
Jan 10, 2008 at 12:15 PM
When a partial class with summary appears in multiple files, instead of only one summary being used all of them are appended and appear like this in the class description: "A class description. A class description. A class description. A class description." Is there any way to get the compiler to ignore the duplicates?

My other annoyance is that the 1.x help file has a flattened TOC. Is there an option in SHFB that I am overlooking to generate a TOC that is actually a tree?

Thanks. :)
Coordinator
Jan 10, 2008 at 3:11 PM
Regarding the merged comments, there is no compiler option that I'm aware of that will get it to not merge the comments. You're best bet is to do it manually by putting all comments on only the main class declaration and leaving them off of the other partial parts.

Regarding the TOC, there is no built-in option to create a nested hierarchy. It could be done with a plug-in but I haven't written one and nor has anyone else that I'm aware of. I do know of one person that wrote a command line tool to do it quite a while ago. I'll see if I can find the reference to it but I'm not sure how well it will work with the latest CTP as quite a lot has changed since then.

Eric
Jan 11, 2008 at 12:16 PM
Most likely you are abusing this partial classes thing, consider a redesign.

Best regards,
Paul.
Jan 12, 2008 at 1:51 PM
Edited Jan 12, 2008 at 1:52 PM
Thanks for the suggestions. I have several dozen classes under a single common namespace so splitting classes into seperate files comes in very handy. The easiest option is to just remove the extra comments.

Cheers.