Packages

object StateValueFn

Constructors and classes associated with StateValueFn.

Source
StateValueFn.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. StateValueFn
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. case class Base[Obs, T](m: Map[Obs, T], default: T) extends StateValueFn[Obs, T] with Product with Serializable

    Basic implementation of a StateValueFn that stores any value supplied to update in an internal immutable map.

    Basic implementation of a StateValueFn that stores any value supplied to update in an internal immutable map.

    m

    the immutable map used for storage.

    default

    value returned by Base when queried for some observation it hasn't yet seen.

  2. case class Folded[Obs, T, U](base: StateValueFn[Obs, T], prepare: (U) ⇒ T, present: (T) ⇒ U) extends StateValueFn[Obs, U] with Product with Serializable

    StateValueFn implementation that implements a fold.

    StateValueFn implementation that implements a fold.

    Any value supplied to update will be transformed first by prepare before being passed to the base StateValueFn. Any value retrieved by stateValue will be passed to present before being returned.

  3. case class Mergeable[Obs, T](base: StateValueFn[Obs, T])(implicit T: Semigroup[T]) extends StateValueFn[Obs, T] with Product with Serializable

    StateValueFn implementation that merges values passed to update into the value stored by the base StateValueFn using the supplied Semigroup's plus function.

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  6. def empty[Obs, T](default: T): StateValueFn[Obs, T]

    Returns an empty StateValueFn backed by an immutable map.

    Returns an empty StateValueFn backed by an immutable map. The supplied default value will be returned by StateValueFn.stateValue for any obs that's not been seen by the StateValueFn.

  7. def empty[Obs, T]: StateValueFn[Obs, Option[T]]

    Returns an empty StateValueFn backed by an immutable map.

  8. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  9. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  10. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. def fromAggregator[Obs, T, U](agg: MonoidAggregator[U, T, U]): StateValueFn[Obs, U]

    Returns a StateValueFn that:

    Returns a StateValueFn that:

    • uses the MonoidAggregator's monoid.zero as an initial value
    • merges values in using the aggregator's monoid
    • prepares and presents using the aggregator's analogous functions
  12. def fromAggregator[Obs, T, U](default: T, agg: Aggregator[U, T, U]): StateValueFn[Obs, U]

    Returns a StateValueFn that:

    Returns a StateValueFn that:

    • uses the supplied default as an initial value
    • merges values in using the aggregator's semigroup
    • prepares and presents using the aggregator's analogous functions
  13. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  14. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  15. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  16. def mergeable[Obs, T](default: T)(implicit T: Semigroup[T]): StateValueFn[Obs, T]

    Returns an empty StateValueFn backed by an immutable map that uses the supplied default as a default value, and merges new learned values into the value in the underlying map using the Semigroup's plus function.

  17. def mergeable[Obs, T](implicit T: Monoid[T]): StateValueFn[Obs, T]

    Returns an empty StateValueFn backed by an immutable map that uses the zero of the supplied Monoid as a default value, and merges new learned values into the value in the underlying map using the Monoid's plus function.

  18. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  19. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  20. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  21. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  22. def toString(): String
    Definition Classes
    AnyRef → Any
  23. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  25. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()

Inherited from AnyRef

Inherited from Any

Ungrouped