OfficeIMO

API Reference

Struct

MarkdownSourceSpan

Namespace OfficeIMO.Markdown
Assembly OfficeIMO.Markdown
Base ValueType
Implements
IEquatable<MarkdownSourceSpan>
Modifiers sealed

Source span for markdown syntax nodes.

Inheritance

  • ValueType
  • MarkdownSourceSpan

Constructors

MarkdownSourceSpan 2 overloads
public MarkdownSourceSpan(Int32 startLine, Int32 endLine) #

Create a line-based source span.

Parameters

startLine System.Int32 requiredposition: 0
endLine System.Int32 requiredposition: 1
public MarkdownSourceSpan(Int32 startLine, Int32 startColumn, Int32 endLine, Int32 endColumn, Nullable<Int32> startOffset = null, Nullable<Int32> endOffset = null) #

Create a source span with line, column, and optional normalized-text offsets.

Parameters

startLine System.Int32 requiredposition: 0
startColumn System.Int32 requiredposition: 1
endLine System.Int32 requiredposition: 2
endColumn System.Int32 requiredposition: 3
startOffset System.Nullable{System.Int32} = null optionalposition: 4
endOffset System.Nullable{System.Int32} = null optionalposition: 5

Methods

public Boolean Contains(MarkdownSourceSpan other) #
Returns: Boolean

Returns true when this span fully contains the given span.

Parameters

other OfficeIMO.Markdown.MarkdownSourceSpan requiredposition: 0
public Boolean ContainsLine(Int32 lineNumber) #
Returns: Boolean

Returns true when the span contains the given 1-based line number.

Parameters

lineNumber System.Int32 requiredposition: 0
public Boolean ContainsPosition(Int32 lineNumber, Int32 columnNumber) #
Returns: Boolean

Returns true when the span contains the given 1-based line and column.

Parameters

lineNumber System.Int32 requiredposition: 0
columnNumber System.Int32 requiredposition: 1
Equals 2 overloads
public virtual Boolean Equals(MarkdownSourceSpan other) #
Returns: Boolean

Parameters

obj System.Object requiredposition: 0
Equals(OfficeIMO.Markdown.MarkdownSourceSpan other) #

Parameters

other OfficeIMO.Markdown.MarkdownSourceSpan required
public override Int32 GetHashCode() #
Returns: Int32
public Boolean Overlaps(MarkdownSourceSpan other) #
Returns: Boolean

Returns true when this span overlaps the given span.

Parameters

other OfficeIMO.Markdown.MarkdownSourceSpan requiredposition: 0
public override String ToString() #
Returns: String

Properties

public Int32 StartLine { get; } #

1-based start line.

public Nullable<Int32> StartColumn { get; } #

1-based start column.

public Int32 EndLine { get; } #

1-based end line.

public Nullable<Int32> EndColumn { get; } #

1-based end column.

public Nullable<Int32> StartOffset { get; } #

0-based start offset in the normalized markdown text.

public Nullable<Int32> EndOffset { get; } #

0-based end offset in the normalized markdown text.