Class Commenter
Default implementation of IAddsComment which adds comments before and after node nodes.
Inheritance
System.Object
Commenter
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ZptSharp.SourceAnnotation
Assembly: ZptSharp.dll
Syntax
public class Commenter : IAddsComment
Constructors
| Improve this Doc View SourceCommenter(ILogger<Commenter>)
Initializes a new instance of the Commenter class.
Declaration
public Commenter(ILogger<Commenter> logger)
Parameters
Type | Name | Description |
---|---|---|
Microsoft.Extensions.Logging.ILogger<Commenter> | logger | Logger. |
Methods
| Improve this Doc View SourceAddCommentAfter(INode, String)
Adds a comment immediately after the end of a specified node
.
Declaration
public void AddCommentAfter(INode node, string commentText)
Parameters
Type | Name | Description |
---|---|---|
INode | node | The node after-which the comment should be added. |
System.String | commentText | The text of the DOM comment. |
AddCommentBefore(INode, String)
Adds a comment immediately before the beginning of a specified node
.
Declaration
public void AddCommentBefore(INode node, string commentText)
Parameters
Type | Name | Description |
---|---|---|
INode | node | The node before-which the comment should be added. |
System.String | commentText | The text of the DOM comment. |