scala.tools.scalap.scalax.rules

Rule

trait Rule [-In, +Out, +A, +X] extends (In) ⇒ Result[Out, A, X]

A Rule is a function from some input to a Result. The result may be:

Source
Rule.scala
Linear Supertypes
(In) ⇒ Result[Out, A, X], AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. Rule
  2. Function1
  3. AnyRef
  4. Any
Visibility
  1. Public
  2. All

Abstract Value Members

  1. def apply (v1: In): Result[Out, A, X]

    Attributes
    abstract
    Definition Classes
    Function1
  2. val factory : Rules

    Attributes
    abstract

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 !^ [Y] (fx2y: (X) ⇒ Y): Rule[In, Out, A, Y]

    Maps an Error

  4. def ## (): Int

    Attributes
    final
    Definition Classes
    AnyRef → Any
  5. def - [In2 <: In] (exclude: ⇒ Rule[In2, Any, Any, Any]): Rule[In2, Out, A, X]

  6. def -^ [B] (b: B): Rule[In, Out, B, X]

  7. def -~ [Out2, B, X2 >: X] (next: ⇒ Rule[Out, Out2, B, X2]): Rule[In, Out2, B, X2]

  8. def -~! [Out2, B, X2 >: X] (next: ⇒ Rule[Out, Out2, B, X2]): Rule[In, Out2, B, Any]

  9. def <~: [InPrev, B, X2 >: X] (prev: ⇒ Rule[InPrev, In, (A) ⇒ B, X2]): Rule[InPrev, Out, B, X2]

    Apply the result of this rule to the function returned by the previous rule

  10. def == (arg0: AnyRef): Boolean

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

    Attributes
    final
    Definition Classes
    Any
  12. def >-> [Out2, B, X2 >: X] (fa2resultb: (A) ⇒ Result[Out2, B, X2]): Rule[In, Out2, B, X2]

  13. def >> [Out2, B, X2 >: X] (fa2ruleb: (A) ⇒ (Out) ⇒ Result[Out2, B, X2]): Rule[In, Out2, B, X2]

  14. def >>& [B, X2 >: X] (fa2ruleb: (A) ⇒ (Out) ⇒ Result[Any, B, X2]): Rule[In, Out, B, X2]

  15. def >>? [Out2, B, X2 >: X] (pf: PartialFunction[A, Rule[Out, Out2, B, X2]]): Rule[In, Out2, B, X2]

  16. def >~> [Out2, B1, B2, B >: A, C, X2 >: X] (f: (B1, B2) ⇒ (Out) ⇒ Result[Out2, C, X2])(implicit arg0: (B) ⇒ ~[B1, B2]): Rule[In, Out2, C, X2]

    >~>(f) is equivalent to >> { case b1 ~ b2 => f(b1, b2) }

  17. def ?? (pf: PartialFunction[A, Any]): Rule[In, Out, A, X]

  18. def ^-^ [B1, B2 >: A, C] (f: (B1, B2) ⇒ C): Rule[In, Out, (B1) ⇒ C, X]

    -(f) is equivalent to ^^ { b2 => b1 => f(b1, b2) }

  19. def ^^ [B] (fa2b: (A) ⇒ B): Rule[In, Out, B, X]

  20. def ^^? [B] (pf: PartialFunction[A, B]): Rule[In, Out, B, X]

  21. def ^~>~^ [B1, B2, B3, B >: A, C] (f: (B1, B2, B3) ⇒ C)(implicit arg0: (B) ⇒ ~[B2, B3]): Rule[In, Out, (B1) ⇒ C, X]

    ~>~(f) is equivalent to ^^ { case b2 ~ b3 => b1 => f(b1, b2, b3) }

  22. def ^~^ [B1, B2, B >: A, C] (f: (B1, B2) ⇒ C)(implicit arg0: (B) ⇒ ~[B1, B2]): Rule[In, Out, C, X]

    ~(f) is equivalent to ^^ { case b1 ~ b2 => f(b1, b2) }

  23. def ^~~^ [B1, B2, B3, B >: A, C] (f: (B1, B2, B3) ⇒ C)(implicit arg0: (B) ⇒ ~[~[B1, B2], B3]): Rule[In, Out, C, X]

    ~~(f) is equivalent to ^^ { case b1 ~ b2 ~ b3 => f(b1, b2, b3) }

  24. def ^~~~^ [B1, B2, B3, B4, B >: A, C] (f: (B1, B2, B3, B4) ⇒ C)(implicit arg0: (B) ⇒ ~[~[~[B1, B2], B3], B4]): Rule[In, Out, C, X]

    ~~~(f) is equivalent to ^^ { case b1 ~ b2 ~ b3 ~ b4 => f(b1, b2, b3, b4) }

  25. def ^~~~~^ [B1, B2, B3, B4, B5, B >: A, C] (f: (B1, B2, B3, B4, B5) ⇒ C)(implicit arg0: (B) ⇒ ~[~[~[~[B1, B2], B3], B4], B5]): Rule[In, Out, C, X]

    ~~~~(f) is equivalent to ^^ { case b1 ~ b2 ~ b3 ~ b4 ~ b5 => f(b1, b2, b3, b4, b5) }

  26. def ^~~~~~^ [B1, B2, B3, B4, B5, B6, B >: A, C] (f: (B1, B2, B3, B4, B5, B6) ⇒ C)(implicit arg0: (B) ⇒ ~[~[~[~[~[B1, B2], B3], B4], B5], B6]): Rule[In, Out, C, X]

    ~~~~~(f) is equivalent to ^^ { case b1 ~ b2 ~ b3 ~ b4 ~ b5 ~ b6 => f(b1, b2, b3, b4, b5, b6) }

  27. def ^~~~~~~^ [B1, B2, B3, B4, B5, B6, B7, B >: A, C] (f: (B1, B2, B3, B4, B5, B6, B7) ⇒ C)(implicit arg0: (B) ⇒ ~[~[~[~[~[~[B1, B2], B3], B4], B5], B6], B7]): Rule[In, Out, C, X]

    ~~~~~~(f) is equivalent to ^^ { case b1 ~ b2 ~ b3 ~ b4 ~ b5 ~ b6 => f(b1, b2, b3, b4, b5, b6) }

  28. def andThen [A] (g: (Result[Out, A, X]) ⇒ A): (In) ⇒ A

    Definition Classes
    Function1
  29. def as (name: String): Rule[In, Out, A, X] with Name

  30. def asInstanceOf [T0] : T0

    Attributes
    final
    Definition Classes
    Any
  31. def clone (): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  32. def compose [A] (g: (A) ⇒ In): (A) ⇒ Result[Out, A, X]

    Definition Classes
    Function1
  33. def eq (arg0: AnyRef): Boolean

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

    Definition Classes
    AnyRef → Any
  35. def filter (f: (A) ⇒ Boolean): Rule[In, Out, A, X]

  36. def finalize (): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  37. def flatMap [Out2, B, X2 >: X] (fa2ruleb: (A) ⇒ (Out) ⇒ Result[Out2, B, X2]): Rule[In, Out2, B, X2]

  38. def getClass (): java.lang.Class[_]

    Attributes
    final
    Definition Classes
    AnyRef → Any
  39. def hashCode (): Int

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

    Attributes
    final
    Definition Classes
    Any
  41. def map [B] (fa2b: (A) ⇒ B): Rule[In, Out, B, X]

  42. def mapResult [Out2, B, Y] (f: (Result[Out, A, X]) ⇒ Result[Out2, B, Y]): Rule[In, Out2, B, Y]

  43. def ne (arg0: AnyRef): Boolean

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

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

    Attributes
    final
    Definition Classes
    AnyRef
  46. def orElse [In2 <: In, Out2 >: Out, A2 >: A, X2 >: X] (other: ⇒ Rule[In2, Out2, A2, X2]): Rule[In2, Out2, A2, X2]

  47. def orError [In2 <: In] : Rule[In2, Out, A, Any]

  48. def synchronized [T0] (arg0: ⇒ T0): T0

    Attributes
    final
    Definition Classes
    AnyRef
  49. def toString (): String

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

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

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

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  53. def | [In2 <: In, Out2 >: Out, A2 >: A, X2 >: X] (other: ⇒ Rule[In2, Out2, A2, X2]): Rule[In2, Out2, A2, X2]

  54. def ~ [Out2, B, X2 >: X] (next: ⇒ Rule[Out, Out2, B, X2]): Rule[In, Out2, ~[A, B], X2]

  55. def ~! [Out2, B, X2 >: X] (next: ⇒ Rule[Out, Out2, B, X2]): Rule[In, Out2, ~[A, B], Any]

  56. def ~++ [Out2, B >: A, X2 >: X] (next: ⇒ Rule[Out, Out2, Seq[B], X2]): Rule[In, Out2, List[B], X2]

  57. def ~- [Out2, B, X2 >: X] (next: ⇒ Rule[Out, Out2, B, X2]): Rule[In, Out2, A, X2]

  58. def ~-! [Out2, B, X2 >: X] (next: ⇒ Rule[Out, Out2, B, X2]): Rule[In, Out2, A, Any]

  59. def ~> [Out2, B, X2 >: X] (next: ⇒ Rule[Out, Out2, (A) ⇒ B, X2]): Rule[In, Out2, B, X2]

    Apply the result of this rule to the function returned by the next rule

Inherited from (In) ⇒ Result[Out, A, X]

Inherited from AnyRef

Inherited from Any