trait _flow[A] extends AnyRef
Ordering
- Alphabetic
Inherited
- Flow._extend._flow
- scala.AnyRef
- scala.Any
- Hide All
- Show All
Visibility
- Public
- All
Method
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
-
def
sequential: Stream[A]
Restores potentially parallel Flow back to Stream
If this is already a Stream, the operation is instant, returning this
Otherwise the operation is quite expensive
In many cases it is advisable to consume pipeline as Flow instead of converting to Stream
val (count, millis) = (1 to 1000).all .parallel // Switching to parallel Stream.Flow .peek(_ => Thread.sleep(1)) // Expensive operation .sequential // Back to Stream .countAndMillis println("Count = " + count + ", done in " + millis / 1000F + " secs") // Output Count = 1000, done in 0.224 secs // Note: We have 1000 elements each pausing for 1 millis. // Without parallel processing total time would be over 1 second
- Definition Classes
- _flow
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
Flow Control