c# xml doc: show only the property name of <see cref="Class.Property">

Viewed 277

I have added this xml doc to my method:

/// <summary>
///   Create an <see cref="ArgumentOutOfRangeException" /> with the message<br />
///   "The value '<paramref name="i_value" />' is out of the range of '<paramref name="i_range" />.<see cref="IRange{T}.LowerValue"/>' to '<paramref name="i_range" />.<see cref="IRange{T}.UpperValue"/>'."
/// </summary>
public static Exception Create_ArgumentOutOfRange<T> (string?    i_prefix,
                                                      object     i_value,
                                                      IRange<T>  i_range,
                                                      string?    i_suffix         = null,
                                                      Exception? i_innerException = null)

and the xml doc is shown as enter image description here
which is quite ugly and difficult to read.

Is there a way of leaving out "IRange<out T>" of the message, but still referring to the code element?

If I used the property on the argument directly:

///   "The value '<paramref name="i_value" />' is out of the range of '<paramref name="i_range.LowerValue" />' to '<paramref name="i_range.UpperValue" />'."

then I get enter image description here
which is not that ugly, but the property name is written twice, and thus wrong and misleading.

0 Answers
Related