Visual Studio: Warn on Missing XML Documentation f

2019-06-21 04:46发布

I am using Visual Studio 2005 (VS.8.0) and I am looking to enforce the requirement that all class members, not just the public ones, be documented. While trivial to setup Visual Studio to generate warnings when public, protected, or internal protected members are not documented, I am looking for a way to have the private and internal members throw this same warning. Any suggestions?

NOTE: I am using warning level 4, am treating Warnings as Errors, and have the Generate XML flag set.

1条回答
三岁会撩人
2楼-- · 2019-06-21 04:49

Unfortunately, Visual Studio 2005 doesn't provide a way to enforce XML documentation on private or internal members and types.

I would recommend giving StyleCop a try, but it doesn't support Visual Studio 2005 (in fact, the latest version doesn't even support Visual Studio 2008 anymore, unfortunately). However, StyleCop can be setup to enforce documentation on all members.

But all is not lost as StyleCop is now open source, so you could obtain the source code and use it to inspire your own add-on for Visual Studio 2005 that mimics this particular operation.

查看更多
登录 后发表回答