doc Replace the word stage by operator in stream doc (#25138)

This commit is contained in:
Richard Imaoka 2018-05-29 17:00:48 +09:00 committed by Arnout Engelen
parent 1919f222fa
commit a17a61557c
142 changed files with 341 additions and 341 deletions

View file

@ -408,14 +408,14 @@ public class GraphStageDocTest extends AbstractJavaTest {
public void demonstrateChainingOfGraphStages() throws Exception {
Graph<SinkShape<Integer>, CompletionStage<String>> sink = Sink.fold("", (acc, n) -> acc + n.toString());
//#graph-stage-chain
//#graph-operator-chain
CompletionStage<String> resultFuture = Source.from(Arrays.asList(1,2,3,4,5))
.via(new Filter<Integer>((n) -> n % 2 == 0))
.via(new Duplicator<Integer>())
.via(new Map<Integer, Integer>((n) -> n / 2))
.runWith(sink, mat);
//#graph-stage-chain
//#graph-operator-chain
assertEquals("1122", resultFuture.toCompletableFuture().get(3, TimeUnit.SECONDS));
}

View file

@ -28,7 +28,7 @@ public class GraphStageLoggingDocTest extends AbstractJavaTest {
@Test
public void compileOnlyTestClass() throws Exception { }
//#stage-with-logging
//#operator-with-logging
public class RandomLettersSource extends GraphStage<SourceShape<String>> {
public final Outlet<String> out = Outlet.create("RandomLettersSource.in");
@ -65,6 +65,6 @@ public class GraphStageLoggingDocTest extends AbstractJavaTest {
};
}
}
//#stage-with-logging
//#operator-with-logging
}