Table of Contents

Class Comment

Namespace
ICSharpCode.Decompiler.CSharp.Syntax
Assembly
ICSharpCode.Decompiler.dll
public class Comment : AstNode, IAnnotatable, IFreezable, INode, ICloneable
Inheritance
Comment
Implements
Inherited Members
Extension Methods

Constructors

Comment(CommentType, TextLocation, TextLocation)

public Comment(CommentType commentType, TextLocation startLocation, TextLocation endLocation)

Parameters

commentType CommentType
startLocation TextLocation
endLocation TextLocation

Comment(string, CommentType)

public Comment(string content, CommentType type = CommentType.SingleLine)

Parameters

content string
type CommentType

Properties

CommentType

public CommentType CommentType { get; set; }

Property Value

CommentType

Content

public string Content { get; set; }

Property Value

string

EndLocation

public override TextLocation EndLocation { get; }

Property Value

TextLocation

IsDocumentation

Returns true if the CommentType is Documentation or MultiLineDocumentation.

public bool IsDocumentation { get; }

Property Value

bool

NodeType

public override NodeType NodeType { get; }

Property Value

NodeType

StartLocation

public override TextLocation StartLocation { get; }

Property Value

TextLocation

StartsLine

public bool StartsLine { get; set; }

Property Value

bool

Methods

AcceptVisitor(IAstVisitor)

public override void AcceptVisitor(IAstVisitor visitor)

Parameters

visitor IAstVisitor

AcceptVisitor<T>(IAstVisitor<T>)

public override T AcceptVisitor<T>(IAstVisitor<T> visitor)

Parameters

visitor IAstVisitor<T>

Returns

T

Type Parameters

T

AcceptVisitor<T, S>(IAstVisitor<T, S>, T)

public override S AcceptVisitor<T, S>(IAstVisitor<T, S> visitor, T data)

Parameters

visitor IAstVisitor<T, S>
data T

Returns

S

Type Parameters

T
S

DoMatch(AstNode, Match)

protected override bool DoMatch(AstNode other, Match match)

Parameters

other AstNode
match Match

Returns

bool