org.bitbucket.inkytonik.kiama.util

ParsingREPLBase

trait ParsingREPLBase[T, C <: REPLConfig] extends REPLBase[C]

A REPL that parses its input lines into a value (such as an abstract syntax tree), then processes them. Output is emitted using a configurable emitter.

Source
REPL.scala
Linear Supertypes
REPLBase[C], AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. ParsingREPLBase
  2. REPLBase
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def banner: String

    Banner message that is printed before the REPL starts.

    Banner message that is printed before the REPL starts.

    Definition Classes
    REPLBase
  2. abstract def createConfig(args: Seq[String]): C

    Create the configuration for a particular run of the REPL.

    Create the configuration for a particular run of the REPL. If supplied, use emitter instead of a standard output emitter.

    Definition Classes
    REPLBase
  3. abstract def parse(source: Source): ParseResult[T]

    Parse a source, returning a parse result.

  4. abstract def process(source: Source, t: T, config: C): Unit

    Process a user input value in the given configuration.

Concrete Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def createAndInitConfig(args: Seq[String]): Either[String, C]

    Create and initialise the configuration for a particular run of the REPL.

    Create and initialise the configuration for a particular run of the REPL. Default: call createConfig and then initialise the resulting configuration. Returns either the created configuration or an error message describing why the configuration couldn't be created.

    Definition Classes
    REPLBase
  9. def driver(args: Seq[String]): Unit

    Driver for this REPL.

    Driver for this REPL. First, use the argument list to create a configuration for this execution. If the arguments parse ok, then print the REPL banner. Read lines from the console and pass non-null ones to processline. If ignoreWhitespaceLines is true, do not pass lines that contain just whitespace, otherwise do. Continue until processline returns false. Call prompt each time input is about to be read.

    Definition Classes
    REPLBase
  10. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  11. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  12. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  14. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  15. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  16. def main(args: Array[String]): Unit

    The entry point for this REPL.

    The entry point for this REPL.

    Definition Classes
    REPLBase
  17. val messaging: Messaging

    The messaging facilitiy used by this REPL.

    The messaging facilitiy used by this REPL.

    Definition Classes
    REPLBase
  18. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  19. final def notify(): Unit

    Definition Classes
    AnyRef
  20. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  21. val positions: Positions

    The position store used by this REPL.

    The position store used by this REPL.

    Definition Classes
    REPLBase
  22. final def processconsole(console: Console, prompt: String, config: C): C

    Process interactively entered lines, one by one, until end of file.

    Process interactively entered lines, one by one, until end of file.

    Definition Classes
    REPLBase
    Annotations
    @tailrec()
  23. def processfile(filename: String, config: C): C

    Process a file argument by passing its contents line-by-line to processline.

    Process a file argument by passing its contents line-by-line to processline.

    Definition Classes
    REPLBase
  24. final def processfiles(config: C): C

    Process the files one by one, allowing config to be updated each time and updated config to be used by the next file.

    Process the files one by one, allowing config to be updated each time and updated config to be used by the next file.

    Definition Classes
    REPLBase
  25. def processline(source: Source, console: Console, config: C): Option[C]

    Process a user input line by parsing it to get a value of type T, then passing it to the process method.

    Process a user input line by parsing it to get a value of type T, then passing it to the process method. Returns the configuration unchanged.

    Definition Classes
    ParsingREPLBaseREPLBase
  26. def processlines(config: C): Unit

    Process interactively entered lines, one by one, until end of file.

    Process interactively entered lines, one by one, until end of file. Prompt with the given prompt.

    Definition Classes
    REPLBase
  27. val profiler: Profiler

    Profiler for this compiler.

    Profiler for this compiler.

    Definition Classes
    REPLBase
  28. def prompt: String

    Define the prompt (default: "> ").

    Define the prompt (default: "> ").

    Definition Classes
    REPLBase
  29. def report(source: Source, messages: Messages, config: C): Unit

    Output the messages in order of position using the given configuration, which defaults to that configuration's output.

  30. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  31. def toString(): String

    Definition Classes
    AnyRef → Any
  32. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  33. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  34. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from REPLBase[C]

Inherited from AnyRef

Inherited from Any

Ungrouped