VB.NET: how to reference common classes and methods in xml documentation

Note . This is a copy of this question , but for Visual Basic instead of C #.

When writing XML documentation, you can use <see cref="something">something</see>one that works, of course. But how do you refer to a class or method with common types?

Public Class FancyClass(Of T)

  Public Function  FancyMethod(value As T) As String
    Return "something fancy"
  End Function

End Class

If I was going to write xml documentation somewhere, how could I refer to a fancy class? how can i refer to FancyClass(Of String)? What about the method?

For example, in another class, I wanted to tell the user that I would return an instance FancyClass(Of Integer). How can I do for this see cref?

+5
source share
2 answers

, VS2012, ​​ VS2013; <see cref="FancyClass(Of T)" />.

+2

- :

''' <summary>
''' A great fancy class.
''' </summary>
''' <typeparam name="T">Generic stuff ....</typeparam>
Public Class FancyClass(Of T)

    ''' <summary>
    ''' A fancy method that do fancy operation.
    ''' </summary>
    ''' <param name="value">The value.</param>
    ''' <returns></returns>
    Public Function FancyMethod(value As T) As String
        Return "something fancy"
    End Function

End Class

xml . FancyClass(Of String): .

0

All Articles