How to copy .NET API documentation?

If the class implements the method defined in the interface, you can choose whether you duplicate the documentation or refer to it using <see cref="..." /> .

 public interface IPerformer { /// <summary> /// Do something useful. /// </summary> /// <param name="something">Object to do something with</param> void Do(Something something); } public class Implementation : IPerformer { /// <copy from="IPerformer" /> # that is what I want! public void Do(Something something) { // implementation ... } } 

Is it possible for the Sandcastle API documentation tool to automatically copy the documentation (which would make reading the API documentation more convenient)? Something like @inheritDoc from Java Doc?

+7
source share
4 answers

Sandcastle hint file creator (SHFB) provides this function through the inheritdoc tag .

+3
source

Not exactly the answer you are looking for, but GhostDoc can do it for you. It will pull the comments from the interface into the implementation.

+4
source

Jetbrain Resharper allows you to copy comments from an interface (or when you create an instance from an interface, it automatically copies them for you), but if you update a comment for an interface, you will have to delete the comments and copy the comments from the database again

+3
source

Documentation AtomineerUtils Pro will automatically duplicate the documentation for the base class, interface, and overload. (This is similar to GhostDoc, but it is a much more powerful and customizable documentation generator).

0
source

All Articles