VS2008:自动生成的文件和XML文档 [英] VS2008: Autogenerated files and XML documentation

查看:135
本文介绍了VS2008:自动生成的文件和XML文档的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是一个烦恼,而不是一个问题.我的项目包含许多自动生成的文件(使用mgmtclassgen.exe).当我生成XML文档时,这些自动生成文件中的xml文档警告使我的注释精美的库陷入困境.

This is an annoyance more than a problem. My project contains a number of autogenerated files (using mgmtclassgen.exe). When I generate the XML documentation, my beautifully commented library is plagued by xml documentation warnings from these autogen files.

是否有办法要么a)禁止为这些文件生成文档,要么b)禁止仅针对一组文件的警告CS1591?我显然不想修改自动生成的文件,即使只是添加抑制编译指示也是如此.

Is there a way to either a) suppress generating documentation for these files or b) suppress warning CS1591 just for a set of files? I obviously do not want to modify files that are autogenerated, even if to just add suppression pragmas.

该库和生成的代码都在C#中,并且我正在使用Visual Studio 2008.

The library and generated code are both in C# and I'm using Visual Studio 2008.

推荐答案

AFAIK,您不能仅对某些文件取消此警告.如果这些警告确实使您感到困扰,则可以将自动生成的代码移到单独的程序集中,以禁用XML文档.

AFAIK you cannot suppress this warning only for certain files. You could, if these warnings really bothers you, move the autogenerated code to a separate assembly for which you would disable XML documentation.

这篇关于VS2008:自动生成的文件和XML文档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆