introduction to cyclops-react

Post on 16-Apr-2017

555 Views

Category:

Technology

1 Downloads

Preview:

Click to see full reader

TRANSCRIPT

AOL’s return to Open Source and

Java 8 cambrian explosion

Inspiration

JDK Libraries

Unify the JDK

Stream Transform

JDK

Optional Transform

JDK

CompletableFuture Transform

JDK

List Transform

JDK

FutureW Transform

cycl

ops-

reac

t

Functor

cycl

ops-

reac

t

Implement Functor

cycl

ops-

reac

t

Functor Transform

cycl

ops-

reac

t

ListX Transform

cycl

ops-

reac

t

JDK Type Extended TypeStream ReactiveSeq

LazyFutureStream

Optional Maybe

CompletableFuture FutureW

List ListX, PStackX, PVectorX

Set, SortedSet SetX, SortedSetX, PSetX, POrderedSetX

Any class with ‘map’ AnyM

impl

emen

ts

Func

tor

Why does this matter?

Nested Stream

For Comprehension

Reactor Comprehension

Unify the libs

reactive-streams

reactive-streams flatMap

Reactor

reactive-streams flatMap

Reactor cyclops-react

reactive-streams flatMap

Reactor cyclops-react

reactive-streams Project Reactor

Project Reactor amb

reactive-streams Reactor cyclops-react

reactive-streams basic interop

Reactor cyclops-react

reactive-streams one liner

Reactor cyclops-react

reactive-streams support?

reactive-streams Javaslang Functional Java

reactive-streams support?

reactive-streams Javaslang Functional Java cyclops-react

reactive-streams interop

Reactor cyclops-react Javaslang Functional Java

Iterable

Iterable flatMap

Javaslang cyclops-react

Iterable flatMap

Javaslang cyclops-react

Iterable flatMap

Javaslang Functional Java

Iterable flatMap

Javaslang Functional Java

Abstracting over flatMap

AnyM wrap Any Monad

Javaslang cyclops-react Functional Java

AnyM flatMap

Javaslang cyclops-react Functional Java

flatMap operations

sequence : Stream / Future

JDK

generic sequence

JDK cyclops-react

sequence : Stream / Future

JDK cyclops-react

sequence : Stream / Array

JDK Javaslang cyclops-react

How far can we take this?

Monad Transformers?

Nested Lists

Double Lists

Double Lists via Transformer

Back to Stream

Sum Lists

Sum Lists via Transformer

sequence : Stream / List

JDK cyclops-react

sequence : Stream / ListT

JDK cyclops-react

Thank You.

top related