You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Related to ticket #89, we are introducing a type-class hierarchy that should express Monix's exposed types (Task, Coeval, Observable).
the purpose isn't to replace libraries like Cats or Scalaz, but because the core depending on such a library is undesirable, the approach is to provide "shims" for Monad and Applicative and then convert those, inspired by djspiewak/shims
the exposed type-classes need to cover Monix's exposed functionality and nothing else
the integration with Cats and Scalaz will be at the top of the stack
This integration is actually more difficult than anticipated, because it requires type-class design and research. Hence I'm pushing it for a later 2.1 release. 2.0 will contain a simplified hierarchy of type-classes that covers the monix.eval.
Thus we currently have:
monix.types.Zippable: for functors supporting the zip / zipWith operations
monix.types.Recoverable: equivalent of MonadError
monix.types.Deferrable: for monadic contexts in which we can lift non-strict values (e.g. now vs evalOnce, evalAlways), that can be deferred and whose results can be memoized
monix.types.Evaluable: for monadic contexts that will eventually produce a single value as a result, either synchronously or asynchronously (e.g. both Task and Coeval are Evaluable but not Observable)
monix.types.Restartable: computations that can be restarted (e.g. Task, Coeval and Observable are all restartable, a java.lang.Iterable would also be restartable, but a java.lang.Iterator wouldn't be restartable (or a Scala Stream for that matter)
monix.types.Asynchronous: computations that execute asynchronously, that can have delayed execution or result signaling and that are recoverable
monix.types.ReactivePublisher: data sources that can be converted to org.reactivestreams.Publisher (e.g. Observable, Task)
This list is subject to change and these types considered slightly unstable. This list is settled for 2.0 though, new types will be added in 2.1 to cover streaming (e.g. async foldable, etc.).
The text was updated successfully, but these errors were encountered:
Related to ticket #89, we are introducing a type-class hierarchy that should express Monix's exposed types (Task, Coeval, Observable).
Monad
andApplicative
and then convert those, inspired by djspiewak/shimsThis integration is actually more difficult than anticipated, because it requires type-class design and research. Hence I'm pushing it for a later 2.1 release. 2.0 will contain a simplified hierarchy of type-classes that covers the
monix.eval
.Thus we currently have:
monix.types.Zippable
: for functors supporting thezip
/zipWith
operationsmonix.types.Recoverable
: equivalent ofMonadError
monix.types.Deferrable
: for monadic contexts in which we can lift non-strict values (e.g.now
vsevalOnce
,evalAlways
), that can be deferred and whose results can be memoizedmonix.types.Evaluable
: for monadic contexts that will eventually produce a single value as a result, either synchronously or asynchronously (e.g. both Task and Coeval are Evaluable but not Observable)monix.types.Restartable
: computations that can be restarted (e.g.Task
,Coeval
andObservable
are all restartable, ajava.lang.Iterable
would also be restartable, but ajava.lang.Iterator
wouldn't be restartable (or a ScalaStream
for that matter)monix.types.Asynchronous
: computations that execute asynchronously, that can have delayed execution or result signaling and that are recoverablemonix.types.ReactivePublisher
: data sources that can be converted toorg.reactivestreams.Publisher
(e.g. Observable, Task)This list is subject to change and these types considered slightly unstable. This list is settled for
2.0
though, new types will be added in2.1
to cover streaming (e.g. async foldable, etc.).The text was updated successfully, but these errors were encountered: