Class/Object

org.specs2.form

Effect

Related Docs: object Effect | package form

Permalink

case class Effect[T](label: String, value: Property[T], decorator: Decorator = Decorator()) extends Executable with DecoratedProperty[Effect[T]] with Product with Serializable

An Effect is a property which is used to display names corresponding to side-effects.

If the side effect throws an exception, the Effect will display it alongside to the label. Otherwise only the label is displayed.

The apply method can be used to execute the Effect effect and possibly get a value out of it (but usually not displayed): Effect(label, 1).apply() must_== 1

The value is stored in a Property object so it will not be evaluated until explicitly queried.

Linear Supertypes
Serializable, Serializable, Product, Equals, DecoratedProperty[Effect[T]], DecoratedLabel[Effect[T]], Executable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Effect
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. DecoratedProperty
  7. DecoratedLabel
  8. Executable
  9. AnyRef
  10. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Effect(label: String, value: Property[T], decorator: Decorator = Decorator())

    Permalink

Value Members

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

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

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

    Permalink
    Definition Classes
    AnyRef → Any
  4. def apply(v: ⇒ T): Effect[T]

    Permalink

    set a new value on the effect

  5. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. def decorateLabel(ns: Any): Any

    Permalink

    do the decoration

    do the decoration

    Definition Classes
    DecoratedLabel
  8. def decorateLabelWith(f: (Any) ⇒ Any): Effect[T]

    Permalink

    set a new Decorator for the label

    set a new Decorator for the label

    Definition Classes
    DecoratedLabel
  9. def decorateValue(ns: Any): Any

    Permalink

    do the decoration

    do the decoration

    Definition Classes
    DecoratedProperty
  10. def decorateValueWith(f: (Any) ⇒ Any): Effect[T]

    Permalink

    set a new Decorator for the value

    set a new Decorator for the value

    Definition Classes
    DecoratedProperty
  11. def decorateWith(f: (Any) ⇒ Any): Effect[T]

    Permalink

    set a new Decorator

    set a new Decorator

    Definition Classes
    DecoratedProperty
  12. val decorator: Decorator

    Permalink
    Definition Classes
    EffectDecoratedLabel
  13. def decoratorIs(d: Decorator): Effect[T]

    Permalink

    set a new Decorator

    set a new Decorator

    Definition Classes
    EffectDecoratedLabel
  14. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  15. def equals(a: Any): Boolean

    Permalink
    Definition Classes
    Effect → Equals → AnyRef → Any
  16. def execute: Result

    Permalink

    executing an effect executes the value and returns success unless there is an Error

    executing an effect executes the value and returns success unless there is an Error

    Definition Classes
    Effect → Executable
  17. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  18. def flatMap[S](f: (T) ⇒ Option[S]): Effect[S]

    Permalink
  19. final def getClass(): Class[_]

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

    Permalink
    Definition Classes
    Effect → AnyRef → Any
  21. def header: Effect[T]

    Permalink

    use this Effect as a header in a table

  22. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  23. val label: String

    Permalink
  24. def labelStyles: String

    Permalink

    return the label styles

    return the label styles

    Definition Classes
    DecoratedLabel
  25. def map[S](f: (T) ⇒ S): Effect[S]

    Permalink
  26. def map(f: (Result) ⇒ Result): Executable

    Permalink
    Definition Classes
    Executable
  27. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  28. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  29. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  30. def styleLabelWith(s: (String, String)): Effect[T]

    Permalink

    set a new style for the label

    set a new style for the label

    Definition Classes
    DecoratedLabel
  31. def styleValueWith(s: (String, String)): Effect[T]

    Permalink

    set a new style for the value

    set a new style for the value

    Definition Classes
    DecoratedProperty
  32. def styleWith(s: (String, String)): Effect[T]

    Permalink

    set a new style

    set a new style

    Definition Classes
    DecoratedProperty
  33. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  34. def toString(): String

    Permalink
    Definition Classes
    Effect → AnyRef → Any
  35. val value: Property[T]

    Permalink
  36. def valueOrResult: Either[Result, T]

    Permalink
  37. def valueStyles: String

    Permalink
    Definition Classes
    DecoratedProperty
  38. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from DecoratedProperty[Effect[T]]

Inherited from DecoratedLabel[Effect[T]]

Inherited from Executable

Inherited from AnyRef

Inherited from Any

Ungrouped