23 lines
483 B
Markdown
23 lines
483 B
Markdown
---
|
|
parents:
|
|
- "[[Вопросы для собеседование Java]]"
|
|
---
|
|
```java
|
|
public class Main {
|
|
|
|
public static void main(String[] args) {
|
|
Uni.createFrom().item("Hello, now ")
|
|
.onItem().transform(s -> getMethod(s))
|
|
.subscribe().with(System.out::println);
|
|
}
|
|
|
|
private static Uni<String> getMethod(String s) {
|
|
return Uni.createFrom().item(s + LocalTime.now());
|
|
}
|
|
|
|
}
|
|
```
|
|
|
|
%%
|
|
ничего не выведет
|
|
%% |