LocationMap

class LocationMap(val input: String)

This is a class to convert linear offset in a string into lines, or the column and line numbers.

This is a class to convert linear offset in a string into lines, or the column and line numbers.

This is useful for display to humans who in text editors think in terms of line and column numbers

Companion
object
class Object
trait Matchable
class Any

Value members

Concrete methods

def getLine(i: Int): Option[String]

return the line without a newline

return the line without a newline

def toLineCol(offset: Int): Option[(Int, Int)]

Given a string offset return the line and column

Given a string offset return the line and column

Concrete fields

val input: String