Class SingleLineComment
A single line comment starting with the specified start code
Implements
Inherited Members
Namespace: FluentMigrator.Runner.BatchParser.RangeSearchers
Assembly: FluentMigrator.Runner.Core.dll
Syntax
public class SingleLineComment : IRangeSearcher
Constructors
SingleLineComment(string)
Initializes a new instance of the SingleLineComment class.
Declaration
public SingleLineComment(string startCode)
Parameters
| Type | Name | Description |
|---|---|---|
| string | startCode | The start code for the single line comment |
SingleLineComment(string, bool)
Initializes a new instance of the SingleLineComment class.
Declaration
public SingleLineComment(string startCode, bool onlyAtBeginningOfLine)
Parameters
| Type | Name | Description |
|---|---|---|
| string | startCode | The start code for the single line comment |
| bool | onlyAtBeginningOfLine | Find the start code only at the beginning of the line |
Properties
EndCodeLength
Gets the length of the end code
Declaration
public int EndCodeLength { get; }
Property Value
| Type | Description |
|---|---|
| int |
IsComment
Is this range a comment?
Declaration
public bool IsComment { get; }
Property Value
| Type | Description |
|---|---|
| bool |
StartCodeLength
Gets the length of the start code
Declaration
public int StartCodeLength { get; }
Property Value
| Type | Description |
|---|---|
| int |
Methods
FindEndCode(ILineReader)
Search for an end code
Declaration
public EndCodeSearchResult FindEndCode(ILineReader reader)
Parameters
| Type | Name | Description |
|---|---|---|
| ILineReader | reader | The reader where the end code is searched |
Returns
| Type | Description |
|---|---|
| EndCodeSearchResult |
|
FindStartCode(ILineReader)
Gets the index into the reader where the start code was found
Declaration
public int FindStartCode(ILineReader reader)
Parameters
| Type | Name | Description |
|---|---|---|
| ILineReader | reader | The reader where the start code is searched |
Returns
| Type | Description |
|---|---|
| int |
|