Skip to content

Interface IXmlDocumentationService

Namespace: Momentum.Extensions.XmlDocs
Assembly: Momentum.Extensions.XmlDocs.dll

Defines a service for loading and retrieving XML documentation comments.

csharp
public interface IXmlDocumentationService

Methods

ClearCache()

Clears all cached documentation.

csharp
void ClearCache()

GetDocumentation(string)

Gets the documentation for a specific member by its XML documentation name.

csharp
XmlDocumentationInfo? GetDocumentation(string memberName)

Parameters

memberName string

The XML documentation member name (e.g., "T:Namespace.Type").

Returns

XmlDocumentationInfo?

The documentation information if found; otherwise, null.

GetMethodDocumentation(MethodInfo)

Gets the documentation for a method.

csharp
XmlDocumentationInfo? GetMethodDocumentation(MethodInfo methodInfo)

Parameters

methodInfo MethodInfo

The method to get documentation for.

Returns

XmlDocumentationInfo?

The documentation information if found; otherwise, null.

GetPropertyDocumentation(PropertyInfo)

Gets the documentation for a property.

csharp
XmlDocumentationInfo? GetPropertyDocumentation(PropertyInfo propertyInfo)

Parameters

propertyInfo PropertyInfo

The property to get documentation for.

Returns

XmlDocumentationInfo?

The documentation information if found; otherwise, null.

GetTypeDocumentation(Type)

Gets the documentation for a type.

csharp
XmlDocumentationInfo? GetTypeDocumentation(Type type)

Parameters

type Type

The type to get documentation for.

Returns

XmlDocumentationInfo?

The documentation information if found; otherwise, null.

LoadDocumentationAsync(string)

Asynchronously loads XML documentation from the specified file.

csharp
Task<bool> LoadDocumentationAsync(string xmlFilePath)

Parameters

xmlFilePath string

The path to the XML documentation file.

Returns

Task<bool>

A task that represents the asynchronous operation. The task result contains true if the documentation was loaded successfully; otherwise, false.