HtmlAttributesExtensions Class
Extensions for a MarkdownObject to allow accessing HtmlAttributes
public static class HtmlAttributesExtensionsMethods
| Name | Description |
|---|---|
| GetAttributes(IMarkdownObject) | Gets or creates the HtmlAttributes stored on a MarkdownObject |
| SetAttributes(IMarkdownObject, HtmlAttributes) | Sets HtmlAttributes to the MarkdownObject |
| TryGetAttributes(IMarkdownObject) | Tries the get HtmlAttributes stored on a MarkdownObject. |
GetAttributes(IMarkdownObject)
HtmlAttributesExtensions.csGets or creates the HtmlAttributes stored on a MarkdownObject
public static HtmlAttributes GetAttributes(this IMarkdownObject obj)SetAttributes(IMarkdownObject, HtmlAttributes)
HtmlAttributesExtensions.csSets HtmlAttributes to the MarkdownObject
public static void SetAttributes(this IMarkdownObject obj, HtmlAttributes attributes)Parameters
objIMarkdownObject- The markdown object.
attributesHtmlAttributes- The attributes to attach.
TryGetAttributes(IMarkdownObject)
HtmlAttributesExtensions.csTries the get HtmlAttributes stored on a MarkdownObject.
public static HtmlAttributes? TryGetAttributes(this IMarkdownObject obj)Parameters
objIMarkdownObject- The markdown object.
Returns
HtmlAttributes? The attached html attributes or null if not found