org.kiama.util

RegexCompiler

trait RegexCompiler [T] extends Compiler[T]

A compiler that uses a Scala combinator character-level parser.

Self Type
RegexCompiler[T] with RegexParsers
Linear Supertypes
Compiler[T], FunSuite, Suite, AbstractSuite, Assertions, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. RegexCompiler
  2. Compiler
  3. FunSuite
  4. Suite
  5. AbstractSuite
  6. Assertions
  7. AnyRef
  8. Any
Visibility
  1. Public
  2. All

Abstract Value Members

  1. val parser : Parser[T]

    The actual parser used to produce the AST.

    The actual parser used to produce the AST.

    Attributes
    abstract
  2. def process (ast: T, console: Console, emitter: Emitter): Boolean

    Function to process the input that was parsed.

    Function to process the input that was parsed. console should be used to read anything needed by the processing. emitter should be used for output. Return true if everything worked, false otherwise. If false is returned, messages about the problem should be logged by process using the messaging facility.

    Attributes
    abstract
    Definition Classes
    Compiler

Concrete Value Members

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

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

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

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

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

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

    Attributes
    final
    Definition Classes
    Any
  7. def assert (o: Option[String]): Unit

    Definition Classes
    Assertions
  8. def assert (o: Option[String], clue: Any): Unit

    Definition Classes
    Assertions
  9. def assert (condition: Boolean, clue: Any): Unit

    Definition Classes
    Assertions
  10. def assert (condition: Boolean): Unit

    Definition Classes
    Assertions
  11. def checkargs (args: Array[String]): Array[String]

    Process the command-line arguments.

    Process the command-line arguments. Returns the arguments that have not been processed. Default: do no processing.

    Definition Classes
    Compiler
  12. def clone (): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  13. def compile (args: Array[String], console: Console): String

    Run the driver using the given args and return the resulting output, which may be error messages or the result of running the compiled program, for example.

    Run the driver using the given args and return the resulting output, which may be error messages or the result of running the compiled program, for example. Read standard input from the specified console. Reset the message buffer before calling the driver.

    Definition Classes
    Compiler
  14. implicit def convertToEqualizer (left: Any): Equalizer

    Attributes
    implicit
    Definition Classes
    Assertions
  15. def dosanitisation : Boolean

    Flag to decide whether to sanitise the output before comparison of test results with expected results (see sanitise method).

    Flag to decide whether to sanitise the output before comparison of test results with expected results (see sanitise method). Default is true; override with false if you want actual results compared.

    Definition Classes
    Compiler
  16. def driver (args: Array[String], console: Console, emitter: Emitter): Unit

    Process the arguments, using the given console for input and the given emitter for output.

    Process the arguments, using the given console for input and the given emitter for output. The arguments are first processed by checkargs. Any remaining arguments are interpreted as file names which are processed in turn by using makeast to turn their contents into abstract syntax trees (ASTs) and then by process which conducts arbitrary processing on the ASTs.

    Definition Classes
    Compiler
  17. def eq (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  18. def equals (arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  19. def execute (testName: String, configMap: Map[String, Any]): Unit

    Attributes
    final
    Definition Classes
    Suite
  20. def execute (testName: String): Unit

    Attributes
    final
    Definition Classes
    Suite
  21. def execute (configMap: Map[String, Any]): Unit

    Attributes
    final
    Definition Classes
    Suite
  22. def execute (): Unit

    Attributes
    final
    Definition Classes
    Suite
  23. def expect (expected: Any)(actual: Any): Unit

    Definition Classes
    Assertions
  24. def expect (expected: Any, clue: Any)(actual: Any): Unit

    Definition Classes
    Assertions
  25. def expectedTestCount (filter: Filter): Int

    Definition Classes
    Suite → AbstractSuite
  26. def fail (cause: Throwable): Nothing

    Definition Classes
    Assertions
  27. def fail (message: String, cause: Throwable): Nothing

    Definition Classes
    Assertions
  28. def fail (message: String): Nothing

    Definition Classes
    Assertions
  29. def fail (): Nothing

    Definition Classes
    Assertions
  30. def filetest (name: String, cp: String, rp: String, console: Console, extra: String = "", args: Array[String] = Array()): Unit

    Make a single file test processing the file cp with comamnd-line arguments args, expecting output as in the file rp.

    Make a single file test processing the file cp with comamnd-line arguments args, expecting output as in the file rp. Use the given console for input. The extra string is used is appended to the normal test title. name is an identifying string used in messages. If the compilation fails, rp is assumed to contain the expected messages.

    Definition Classes
    Compiler
  31. def filetests (name: String, path: String, srcext: String, resext: String, optinext: Option[String] = None, indefault: String = "", argslist: List[Array[String]] = List (Array ())): Unit

    Make tests that process the files in path.

    Make tests that process the files in path. name is an identifying name for this set of tests. All files whose names end in srcext are processed. Processing is done by the function compile which must return either Some (s) where s is the output or None if processing failed. If srcext is .x and resext is .y, then the expected result for foo.x is found in file foo.y. If optinext is Some (z), then foo.z is used for standard input, if it exists, otherwise the string indefault is used. A test fails if either the processing fails or it succeeds with the wrong result. argslist is used to specify the sets of command-line arguments that you want to use. Each test is run with each set of arguments. The default is an empty argument list.

    Definition Classes
    Compiler
  32. def finalize (): Unit

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

    Attributes
    final
    Definition Classes
    AnyRef
  34. def hashCode (): Int

    Definition Classes
    AnyRef → Any
  35. def ignore (testName: String, testTags: Tag*)(f: ⇒ Unit): Unit

    Attributes
    protected
    Definition Classes
    FunSuite
  36. implicit def info : Informer

    Attributes
    protected implicit
    Definition Classes
    FunSuite
  37. def intercept [T <: AnyRef] (f: ⇒ Any)(implicit manifest: Manifest[T]): T

    Definition Classes
    Assertions
  38. def isInstanceOf [T0] : Boolean

    Attributes
    final
    Definition Classes
    Any
  39. def main (args: Array[String]): Unit

    Process the program in the file given as the first command-line argument, read input using JLine input editing, and emit output to the standard output.

    Process the program in the file given as the first command-line argument, read input using JLine input editing, and emit output to the standard output.

    Definition Classes
    Compiler
  40. def makeast (reader: FileReader, filename: String): Either[T, String]

    Make an AST from the file with the given name by parsing it with the parser.

    Make an AST from the file with the given name by parsing it with the parser.

    Definition Classes
    RegexCompilerCompiler
  41. def ne (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  42. def nestedSuites : List[Suite]

    Definition Classes
    Suite → AbstractSuite
  43. def notify (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  44. def notifyAll (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  45. def pending : PendingNothing

    Definition Classes
    Suite
  46. def pendingUntilFixed (f: ⇒ Unit): Unit

    Definition Classes
    Suite
  47. def run (testName: Option[String], reporter: Reporter, stopper: Stopper, filter: Filter, configMap: Map[String, Any], distributor: Option[Distributor], tracker: Tracker): Unit

    Definition Classes
    FunSuite → Suite → AbstractSuite
  48. def runNestedSuites (reporter: Reporter, stopper: Stopper, filter: Filter, configMap: Map[String, Any], distributor: Option[Distributor], tracker: Tracker): Unit

    Attributes
    protected
    Definition Classes
    Suite → AbstractSuite
  49. def runTest (testName: String, reporter: Reporter, stopper: Stopper, configMap: Map[String, Any], tracker: Tracker): Unit

    Attributes
    protected
    Definition Classes
    FunSuite → Suite → AbstractSuite
  50. def runTests (testName: Option[String], reporter: Reporter, stopper: Stopper, filter: Filter, configMap: Map[String, Any], distributor: Option[Distributor], tracker: Tracker): Unit

    Attributes
    protected
    Definition Classes
    FunSuite → Suite → AbstractSuite
  51. def sanitise (s: String): String

    Sanitise the output.

    Sanitise the output. At the moment this means make any Windows line endings appear in Unix style instead. This allows for either program or test output to use either line ending style, but tests will still pass. This will clearly break any tests where the actual line endings matter.

    Definition Classes
    Compiler
  52. def suiteName : String

    Definition Classes
    Suite
  53. def synchronized [T0] (arg0: ⇒ T0): T0

    Attributes
    final
    Definition Classes
    AnyRef
  54. def tags : Map[String, Set[String]]

    Definition Classes
    FunSuite → Suite → AbstractSuite
  55. def test (testName: String, testTags: Tag*)(f: ⇒ Unit): Unit

    Attributes
    protected
    Definition Classes
    FunSuite
  56. def testNames : Set[String]

    Definition Classes
    FunSuite → Suite → AbstractSuite
  57. def testsFor (unit: Unit): Unit

    Attributes
    protected
    Definition Classes
    FunSuite
  58. def toString (): String

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

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

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

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  62. def withClue (clue: Any)(fun: ⇒ Unit): Unit

    Definition Classes
    Assertions
  63. def withFixture (test: NoArgTest): Unit

    Attributes
    protected
    Definition Classes
    Suite → AbstractSuite
  64. def groups : Map[String, Set[String]]

    Attributes
    final
    Definition Classes
    Suite
    Annotations
    @deprecated
    Deprecated

    scala.this.deprecated.init$default$1

Inherited from Compiler[T]

Inherited from FunSuite

Inherited from Suite

Inherited from AbstractSuite

Inherited from Assertions

Inherited from AnyRef

Inherited from Any