XML-documentation for a namespace

前端 未结 7 1172
自闭症患者
自闭症患者 2020-12-14 05:21

Would you write xml-doc for a namespace? And if yes, how and where?

I would think, if it is possible, maybe an almost empty file like this:

/// 

        
7条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-14 06:02

    Sandcastle does not support the NamespaceDoc directly, but if you use Sandcastle Help File Builder you can use the NamespaceDoc class mentioned by Tim.

    namespace Example
    {
        /// 
        ///   
        ///     Summary
        ///   
        /// 
        /// 
        internal class NamespaceDoc
        {
        }
    }
    

    SCHB also extends the syntax slightly and allows embedding code examples straight from code files. An example _Namespace.xml:

    
    
      
        

    Example Namespace

    This namespace is used in the following way: Hopefully this helps!

    Including documentation in XML file allows you to write short summary in code and larger description in a separate XML file for the help file. This way the code isn't cluttered with all the details and remains easily readable.

提交回复
热议问题