Question

I am using GhostDoc to document my methods etc... and its working well but it doesn't fill the <returns> ...

Can anyone tell me what i should be doing i.e

If it returns an object called "Roles" then

<returns>A role object see <see cref = "UserRole" /></returns>

or simply

<returns>A role object</returns>

or

<returns>A role</returns>

I know its sounds a bit being too precise but i want to start off correct :-)

Take for example a standard string return type of a username

<returns>The user name</returns>

<returns>The user name, see <see cref = "system.string" /> </returns>
Was it helpful?

Solution

Taking your cues from MSDN (example 1, example 2):

<returns>A <see cref="string" /> that contains the username</returns>

<returns>An object that contains role information</returns>

A documentation generator will include the type of the return value, so it's not necessary to always included it; however, if it make sense (or you want to point it out) it's not a problem to do so, but probably in the flow the statement, rather than as a separate "see X" statement.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top