xml-comments

Code Commenting: Do you put your code comments on Interfaces or on Concrete classes, or both? [duplicate]

你。 提交于 2019-12-19 05:54:38
问题 This question already has answers here : Comment the interface, implementation or both? (8 answers) Closed 4 months ago . What is the best practice in documenting classes and interfaces. Say if you have a concrete class called Foo, that derives from an interface called IFoo. Where do you put your comments for your methods? Do you duplicate your comments on the Interface as well as the concrete class? Here is an example where comments are duplicated: public class Foo : IFoo { /// <summary> ///

Multiline XML Comments in VB.NET and Visual Studio Intellisense

自古美人都是妖i 提交于 2019-12-17 18:44:24
问题 I'm trying to put newlines in my XML Comments in VB.Net. I've read two other posts about C#, XML multiline comments in C# - what am I doing wrong? Adding line breaks to comments for Intellisense But the suggested <para> or <br/> tags don't work. This, ''' <summary> ''' <para>Line one</para><br /> ''' <para>Line two</para><br /> ''' </summary> ''' <value></value> ''' <returns></returns> ''' <remarks></remarks> Public Property Speed As Double Still appears like this: How can I make this work?

XML multiline comments in C# - what am I doing wrong?

时间秒杀一切 提交于 2019-12-17 16:32:29
问题 According to this article, it's possible to get multiline XML comments -- instead of using /// , use /** */ . This is my interpretation of what multiline comments are, and what I want to have happen: /** * <summary> * this comment is on line 1 in the tooltip * this comment is on line 2 in the tooltip * </summary> */ However, when I use this form, the tooltip that pops up when I hover over my class name in my code is single-line, i.e. it looks exactly as if I had written my comment like this:

Using XPath to access comments a flat hierachy

霸气de小男生 提交于 2019-12-13 14:43:33
问题 I have a given XML document (structure can not be changed) and want to get the comments that are written above the nodes. The document looks like this: <!--Some comment here--> <attribute name="Title">Book A</attribute> <attribute name="Author"> <value>Joe Doe</value> <value>John Miller</value> </attribute> <!--Some comment here--> <attribute name="Code">1</attribute> So comments are optional, but if there is one, I want to get the comment above each attribute. Using /*/comment()[n] would

Documenting an array of type T in vsdoc format for javascript, Did I Find a Bug?

[亡魂溺海] 提交于 2019-12-11 02:21:55
问题 Following these guidelines for vsdoc documentation, I've been unable to get intellisense to work properly for an array of a given type. Here is some code that demos the problem function MyType() { /// <summary>Class description here</summary> /// <field name="PropertyA" type="Boolean">Description of Property A</field> /// <field name="PropertyB" type="String">Description of Property B</field> } MyType.prototype.PropertyA = false; MyType.prototype.PropertyB = ""; function testFunc

Framework goto definition shows comments, are these generated from xml comments?

ぐ巨炮叔叔 提交于 2019-12-10 11:47:14
问题 I was mildly surprised recently to discover that my carefully crafted xml comments weren't showing up in intellisense for my colleagues. Having always used the associated assemblies with project references, I hadn't realised that you had to export the .xml document as well to access this information. This led me to wondering how the .Net framework intellisense works. If I understand correctly, the .xml files must be hidden away somewhere in a special folder? But my main question is about

How do I comment attributes inside an XML tag?

时光总嘲笑我的痴心妄想 提交于 2019-12-09 02:27:47
问题 Is it possible to comment one or several attributes inside an XML tag? Something like /* */ from C. I have tried using <!-- --> , but it was unsuccessful. <element attribute1="value1" attribute2="value2" <!-- attribute3="value3" (commented value) --> > 回答1: No, this isn't possible. Comments are not allowed in an XML open tag. Depending on your application, you might get away with "commenting out" the attributes by prefixing their names with "_", or you might not (if the XML is validated

Java - Reading Comment from XML-File

三世轮回 提交于 2019-12-07 16:46:02
问题 I have to extract comments from a XML-File. I couldn't find a way to get them using JDOM or something else. At the moment I use Regex and FileReader but I don't feel like this is the way to go. Can you use something like JDOM to get comments from a XML-File? Or ist it limited to Elements/Nodes and Attributes? 回答1: You need to implement a lexical handler. More information over here - http://docs.oracle.com/javase/tutorial/jaxp/dom/readingXML.html Look at the Lexical Controls chapter. 回答2: I

c# xml code comment for file reference

房东的猫 提交于 2019-12-07 03:18:19
问题 Is there a tag for a file reference in a xml code comment? The file is a sql script file. Just wondering if there is a better way than something like this ///<summary> ///please have a look at c:\code\project1\sql\file1.sql ///</summary> 回答1: You could use a file URI, this makes it clickable in visual studio: file:///c:/code/project1/sql/file1.sql 回答2: You can mix in elements from other namespaces, including xhtml, so ///<summary> ///please have a look at <a href="file:///c:/code/project1/sql

Autogenerating XML comments in Vb.Net

一个人想着一个人 提交于 2019-12-07 01:35:47
问题 I have recently moved over to coding from c#.net in vb.net In c# i could hit /// above any class/method and Visual Studio would automaticly generate the xml comments body for me. Example /// <summary> /// /// </summary> /// <param name="bar"></param> void foo(string bar) { } How do I get this same behaviour in my vb.net project I have tried ''' and enter or space but it does nothing. I'm using the same IDE for both projects 回答1: You need to set "Generate XML documentation file" in Project