Files
Tagir Valeev dd689d3a39 [java-inspections] More tests for preview
GitOrigin-RevId: 6b6405ee4491ad1d58947547c40df6fb2d291ab7
2022-07-29 17:54:59 +00:00

10 lines
379 B
Java

// "Extract variable 'lc' to 'thenApply' operation" "true-preview"
import java.util.concurrent.CompletableFuture;
public class Test {
public static void main(String[] args) {
CompletableFuture.completedFuture(" XYZ ")
.thenApply(x -> x.trim() + "|" + x.trim()).thenApply(String::toLowerCase)
.thenAccept(lc -> System.out.println(lc));
}
}