He-Pin commented on code in PR #990:
URL: https://github.com/apache/incubator-pekko/pull/990#discussion_r1460406664


##########
docs/src/main/paradox/stream/operators/Flow/exists.md:
##########
@@ -0,0 +1,37 @@
+# exists
+
+Emit true and complete the stream as soon as there's an element satisfy the 
*predicate*, or emit false when upstream
+complete and no element satisfied the *predicate*.
+
+@ref[Simple operators](../index.md#simple-operators)
+
+## Signature
+
+@apidoc[Flow.exists](Flow$) { scala="#exists[I](p:Out%20=%3E%20Boolean)" 
java="#exists[I](p:org.apache.pekko.japi.function.Predicate[I])" }
+
+## Description
+
+Emit true and complete the stream as soon as there's an element satisfy the 
*predicate*, or emit false when upstream
+complete and no element satisfied the *predicate*.

Review Comment:
   Emits completes



##########
docs/src/main/paradox/stream/operators/Flow/exists.md:
##########
@@ -0,0 +1,37 @@
+# exists
+
+Emit true and complete the stream as soon as there's an element satisfy the 
*predicate*, or emit false when upstream
+complete and no element satisfied the *predicate*.
+
+@ref[Simple operators](../index.md#simple-operators)
+
+## Signature
+
+@apidoc[Flow.exists](Flow$) { scala="#exists[I](p:Out%20=%3E%20Boolean)" 
java="#exists[I](p:org.apache.pekko.japi.function.Predicate[I])" }
+
+## Description
+
+Emit true and complete the stream as soon as there's an element satisfy the 
*predicate*, or emit false when upstream
+complete and no element satisfied the *predicate*.
+
+## Examples
+
+Scala
+:  @@snip 
[Exists.scala](/docs/src/test/scala/docs/stream/operators/flow/DiMap.scala) { 
#imports #exists }
+
+Java
+:  @@snip 
[Exists.java](/docs/src/test/java/jdocs/stream/operators/flow/DiMap.java) { 
#imports #exists }

Review Comment:
   Another file instead of Dimap.java?



##########
docs/src/main/paradox/stream/operators/Flow/exists.md:
##########
@@ -0,0 +1,37 @@
+# exists
+
+Emit true and complete the stream as soon as there's an element satisfy the 
*predicate*, or emit false when upstream
+complete and no element satisfied the *predicate*.
+
+@ref[Simple operators](../index.md#simple-operators)
+
+## Signature
+
+@apidoc[Flow.exists](Flow$) { scala="#exists[I](p:Out%20=%3E%20Boolean)" 
java="#exists[I](p:org.apache.pekko.japi.function.Predicate[I])" }
+
+## Description
+
+Emit true and complete the stream as soon as there's an element satisfy the 
*predicate*, or emit false when upstream
+complete and no element satisfied the *predicate*.
+
+## Examples
+
+Scala
+:  @@snip 
[Exists.scala](/docs/src/test/scala/docs/stream/operators/flow/DiMap.scala) { 
#imports #exists }
+
+Java
+:  @@snip 
[Exists.java](/docs/src/test/java/jdocs/stream/operators/flow/DiMap.java) { 
#imports #exists }
+
+## Reactive Streams semantics
+
+@@@div { .callout }
+
+**emits** when predicate returned true or upstream completes
+
+**backpressures** '''Backpressures when'' downstream backpressures
+
+**completes** when predicate returned true or upstream completes

Review Comment:
   Return false



##########
docs/src/main/paradox/stream/operators/Flow/exists.md:
##########
@@ -0,0 +1,37 @@
+# exists
+
+Emit true and complete the stream as soon as there's an element satisfy the 
*predicate*, or emit false when upstream

Review Comment:
   Emits ,complete.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to