Not all namespaces are included into Sandcastle build for documentation

被刻印的时光 ゝ 提交于 2019-12-10 21:18:40

问题


I have a C# project with two namespaces in one solution. I've documented all the classes/functions/members/etc in both namespaces. As this project is a small research project, the namespaces are DocTestLibrary and DocTestLibrary.Events. However, when I try to create documentation from it via Sandcastle, it will only create documentation for the DocTestLibrary namespace. Is there any setting that I need to make in Sandcastle to make this work? I doubt it though, as I've scoured through most of them.

The strange thing is, Doxygen is able to generate documentation just fine.


As to provide some more information, I've checked the log that Sandcastle produces for the build. It seems that this entry is causing the rest not to be displayed.

Warn: ResolveReferenceLinksComponent2: Unknown reference link target 'T:DocTestLibrary.Events.DemoEvent'.

I also found out something else.

The DocTestLibrary namespace consists of two classes:

  • TestClass
  • StaticHelper

As the name implies, the StaticHelper is a helper-class with only static methods. Yet Sandcastle also denies to process this file. Only the TestClass get's processed. It only boggles me that there isn't an entry about this in the log though.


回答1:


In my sandcastle project it would always only include a single namespace of a total 5. The problem was that I did not check Include root namespace container under the section Help File.

Now all my namespaces are listed unter a root namespace.




回答2:


Are all your types in DocTestLibrary.Events internal by any chance? By default, I believe Sandcastle only generates documentation for public types.




回答3:


It seems that this issue is fixed by setting the DocumentInternals in the Visibility properties section in the Sandcastle project. I wonder why this is, as no code is declared internal...

I guess I'll be playing around some more...




回答4:


I've found this issue can be fixed by manually setting the classes you want documented in Edit API Filter under Project Properties -> Visibility.



来源:https://stackoverflow.com/questions/7849679/not-all-namespaces-are-included-into-sandcastle-build-for-documentation

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!