A position in the editor.

Hierarchy

  • Position

Index

Constructors

constructor

  • new Position(lineNumber: number, column: number): Position

Properties

column

column: number

column (the first character in a line is between column 1 and column 2)

lineNumber

lineNumber: number

line number (starts at 1)

Methods

clone

equals

isBefore

  • Test if this position is before other position. If the two positions are equal, the result will be false.

    Parameters

    Returns boolean

isBeforeOrEqual

  • Test if this position is before other position. If the two positions are equal, the result will be true.

    Parameters

    Returns boolean

toString

  • toString(): string
  • Convert to a human-readable representation.

    Returns string

Static compare

Static equals

Static isBefore

  • Test if position a is before position b. If the two positions are equal, the result will be false.

    Parameters

    Returns boolean

Static isBeforeOrEqual

  • Test if position a is before position b. If the two positions are equal, the result will be true.

    Parameters

    Returns boolean

Static isIPosition

  • isIPosition(obj: any): boolean
  • Test if obj is an IPosition.

    Parameters

    • obj: any

    Returns boolean

Static lift