scala.util.regexp

WordExp

class WordExp extends Base

The class WordExp provides regular word expressions. Users have to instantiate type member _regexpT <: RegExp (from class Base) and a type member _labelT <: Label. Here is a short example:

 import scala.util.regexp._
 import scala.util.automata._
 object MyLang extends WordExp {
   type _regexpT = RegExp
   type _labelT = MyChar

case class MyChar(c:Char) extends Label } import MyLang._ // (a* | b)* val rex = Star(Alt(Star(Letter(MyChar('a'))),Letter(MyChar('b')))) object MyBerriSethi extends WordBerrySethi { override val lang = MyLang } val nfa = MyBerriSethi.automatonFrom(Sequ(rex), 1)

attributes: abstract
known subclasses: ContentModel

Inherits

  1. Base
  2. AnyRef
  3. Any

Type Members

  1. class Alt extends RegExp

  2. class Label extends AnyRef

  3. class Letter(a: _labelT) extends RegExp with Product

  4. class Meta extends RegExp

    this class can be used to add meta information to regexps

  5. class RegExp extends AnyRef

  6. class Sequ extends RegExp

  7. class Star(r: _regexpT) extends RegExp with Product

  8. class Wildcard() extends RegExp with Product

  9. type _labelT <: Label

  10. type _regexpT <: RegExp

Value Members

  1. object Alt extends AnyRef

  2. object Eps extends RegExp with Product

  3. object Sequ extends AnyRef

  4. def equals(arg0: Any): Boolean

    This method is used to compare the receiver object (this) with the argument object (arg0) for equivalence

  5. def hashCode(): Int

    Returns a hash code value for the object

  6. def toString(): String

    Returns a string representation of the object

Instance constructors

  1. new WordExp()