I am trying to include a code snippet in my class XML documentation but the compiler complaining that an xml element is not closed!
Here is what I am trying to achieve
/// <summary>
/// Method documentation here...
/// </summary>
/// <remarks>
/// <para>
/// This class should be used as follow:
/// <br/>
/// ************** PROBLEM IN NEXT LINE ********************
/// <c> MyClass class = new MyClass<String>(); </c>
/// </para>
/// </remarks>
public class MyClass<T>{
....
}
I tried to replace the code snippet by /// <c> MyClass class = new MyClass{String}(); </c>
Any one has experienced this before?
Thanks for your help
In xml documentation, you have to replace the triangular braces with curly braces:
The reason you end up forced to do this, it because it genuinely isn’t well formed xml if you allow triangular braces outside of element markup.
The replace you tried is correct.