Source

data class Source(content: String, name: String, path: String)

A source of text to lexers.

Author

AdrianTodt, An Tran

Parameters

content

The content of the source.

name

The name of the source.

path

The path to the source.

Constructors

Source
Link copied to clipboard
common
fun Source(content: String, name: String = "?", path: String = "!!no path!!")

Creates a source based of a string.

Types

Companion
Link copied to clipboard
common
object Companion
Line
Link copied to clipboard
common
data class Line

Represents a line from the source.

Properties

bounds
Link copied to clipboard
common
val bounds: IntRange

The bounds of a given source.

content
Link copied to clipboard
common
val content: String
lines
Link copied to clipboard
common
val lines: List<Source.Line>

The lines of the content.

name
Link copied to clipboard
common
val name: String
path
Link copied to clipboard
common
val path: String