Java 17? ??? ?? ??? ??? ????? ?? ? ??????? ???? ????? ???? ??? ???. ?? ?? ?? ? ??? ?? HttpURLConnection ?? Apache HttpClient? ?? ?? ?????? ?? ??? ? ??? ??? WebClient ??????. ? ?????? WebClient? ??? ??, WebClient? Java?? HTTP ??? ????? ??, ?????? WebClient? ????? ??? ? ?? ??? ???????.
? ?????????
WebClient? Spring WebFlux ??? ????? HTTP ??? ???? ?? ????? ??? ?? ????. ?? ?? ??? ???? WebClient? ??? ?????.
- ??? ??: ??? I/O ??? ?? ??? ?? ???? ??????? ???? ?????.
- ???: API? ???? ?? ?? ??? ??? ?????.
- ???: ?? ???? ??? ???? WebClient? ? ?? ??? ????? ??? ? ????.
- ?? ??? ??: ?? ??, ?? ? ?? ??? ?? ??? ? ????.
?????? ??
Java 17?? WebClient? ????? ?? ????? ???? ?????.
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-webflux</artifactId> </dependency>
???? ??? ??? ?? WebClient ????? ????? ?? ?????.
import org.springframework.web.reactive.function.client.WebClient; public class WebClientExample { private final WebClient webClient; public WebClientExample() { this.webClient = WebClient.builder() .baseUrl("https://jsonplaceholder.typicode.com") .build(); } public String getPosts() { return webClient.get() .uri("/posts") .retrieve() .bodyToMono(String.class) .block(); // Blocks the call for simplicity in this example } }
? ???? ?? WebClient ????? ???? ?? ?? URL? ??? ?? GET ??? ???? JSON ?? ??? API?? ??? ??? ?????. block() ???? ????? ??? ???? ? ?????.
??? ????
WebClient? ??? ??? ??? ??? ?? ??? ? ?? ??? ????. ??? ???? ?? ?? ???? ???? ??? ??? ? ??? ??? ? ????.
import reactor.core.publisher.Mono; public Mono<String> getPostsAsync() { return webClient.get() .uri("/posts") .retrieve() .bodyToMono(String.class); // Non-blocking call }
bodyToMono()?? ??? Mono? ?? ??????? ??? ? ???? ??? ?????? ????? ??? ? ????. ?? ???? ???? ?? ?? ?? ?? ??? ???? ?? ??????? ?? ?????.
?? ??
WebClient? ?? ??? ???? onStatus() ???? ???? ??? ? ????.
public String getPostWithErrorHandling() { return webClient.get() .uri("/posts/9999") // Assuming this post does not exist .retrieve() .onStatus(status -> status.is4xxClientError(), clientResponse -> { System.err.println("Client Error!"); return Mono.error(new RuntimeException("Client error occurred")); }) .onStatus(status -> status.is5xxServerError(), clientResponse -> { System.err.println("Server Error!"); return Mono.error(new RuntimeException("Server error occurred")); }) .bodyToMono(String.class) .block(); }
? ???? 4xx ????? ??? 5xx ?? ??? ?? ???? ?????.
Java 17? ??? ??? ???? ?????? WebClient? ???? HTTP ??? ?? ???? ? ????. ??? ??? ?? ???? ???? ??? ???? ???? WebClient? Java ??????? ?? ?????? ???? ?????. ?? ??? ?? ? ??????? ??? ? ????? ?? ?? ??? ? ??? ?????.
WebClient? ?? ?? ??? Java 17? ?? ???? ??? ?? ? ?? ???? ??? ???!
? ??? Java? WebClient ?? HTTP ??? ???? ???? ??? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!

? AI ??

Undress AI Tool
??? ???? ??

Undresser.AI Undress
???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover
???? ?? ???? ??? AI ?????.

Clothoff.io
AI ? ???

Video Face Swap
??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

?? ??

??? ??

???++7.3.1
???? ?? ?? ?? ???

SublimeText3 ??? ??
??? ??, ???? ?? ????.

???? 13.0.1 ???
??? PHP ?? ?? ??

???? CS6
??? ? ?? ??

SublimeText3 Mac ??
? ??? ?? ?? ?????(SublimeText3)

Java??? ?? ??? ????? ? ?? ?? ???? ????. ??, ?? ??? ??? ??? ?? ? ? ???, ?? ?? ?? ??? ?? ?? ?? ???? ??? ?????. Runnable? run () ????? ?? ?? ??? ??? ?? ?? ? ????? ??? ?????. ??, Callable? ?? ??? ?????? ?? ?? ? ??? ?? ? ????. ?? ????? ????? ??? ???????. ??, Runnable? ??? ?? ExecutorService? ?? ?? ? ? ??? Callable? ExecutorService?? ??? ? ??? ?? ??? ?? ? ? ????.

Java? ??? ?? ??, ?? ? ??? (? : Projectreactor) ? Java19? ?? ???? ??? ??? ?????? ?????. 1. CompletableFuture? ?? ??? ?? ?? ??? ? ?? ??? ????? ?? ??????? ? ?? ??? ?????. 2. Projectreactor? ?? ? ??? ??? ???? ?? ???? ? ??? ???? ?? ? ?????? ?????. 3. ?? ???? ??? ??? ??? I/O ??? ? ??? ???? ?? ??? ????? ??? ???? ????. ? ???? ?? ??? ????? ??? ??? ??? ?? ??? ??? ?????? ???? ???? ?? ?? ??? ??????.

Javanio? Java 1.4? ?? ? ??? IOAPI???. 1) ?? ? ??? ?????, 2) ??, ?? ? ??? ?? ?? ??, 3) ? ??? ??? ???? 4) ?? ??? ?? IO?? ? ????? ?????. 1) ? ?? IO? ??? ?? ??? ???, 2) ??? ??? ?? ???? ?????, 3) ???? ?????? ???? 4) ??? ?? ??? ?? ?? ? ??? ?????. 1) ??? ??/??? ??? ?? ?????, 2) ???? ???? ???? ?? ???? ???????. 3) ??? ??? ??? ???????.

Java?? ??? ?? ?? ??? ???? ? ?????. ?? ???? ??? ?????. 1. ?? ?? ? ???? ??????? ?? ?? ?? ??? ???? ??? ?????. 2. ?? ??, ???, ??? ?? ?? ?? ???? ????? ?? ??? ??? ??? ?????. 3. ENUMMAP ? ENUMSET? ???? ?? ? ?? ???? ???? ??? ???? ? ?????? ?????. 4. ?? ?, ??? ?? ?? ??? ?? ????? ?? ??? ??? ?????.? ????? ?? ???? ????????. ??? ???? ???? ?? ??? ????? ??? ?? ? ??? ?? ?????? ???????.

Java? ????? ????? ??? ??? ?? ???? ?? ?? ??????, ?? ? ???? ? ??? ????. ?? ???? ??? ??? ???? ??? ??? ???? ?? ??? ??? ????. ???? ???? ??? ??, ?? ??? ???? ???? ?? ??? ?? ???? ?? ?????. ???? ?? ?? ??? ?? ?? ??? ?????. ?????? ?? ??? ??? ???? ?? ??? ??? ?? ??? ???? ???? ??? ?? ??? ?????? ???? ????? ??? ?? ?? ???, ?? ? ?? ???? ??? ??? ?????. ???? urlclassl? ?? ??? ??? ??? ?? ? ? ????

JavaprovidesmultiplesynchronizationToolsforthreadsAfety.1.SynchronizedBlocksensUremutualExclusionByLockingMethodSorspecificCodesections.2.reentrantLockofferAdcerAdcenctrol, ratelockandFairnessPolicies.3.ConditionVariablesStowFor

Java ?? ??? ??? ?? ? ??? ???? ?? ??? ???? Try-Catch? ???? ????? ????? ???? ????. 1. IoException? ?? ?? ? ??? ???? ?? ??? ??? ?? ???????. 2. NullPointerException? ?? ???? ?? ??? ????? ???? ?? ??? ?? ???? ??? ?????. 3. ??? ?? ? ?? ??? ???? ??? ??? ?? ????? ???????. 4. CODE? ?? ??? ??? ?? ??? ???? ??? ???? ??? ???? ?? ?? ????. 5. ?? ???? ??? ??? ?? ??? ??? ?? ???? ??? ???????.

?? ?? Java? ?? ???? ?? ? ? ? ????? ????, ? ??? ??? ??? ??? ???? ? ????. 1. ?? ?? hashcode () ???? ???? ?? ?? ???? ?? ??? ?? ?? ???? ?????. 2. ?? ??? ??? ?? ?? ???? ??? ??? ? ????. ?? ??? ?? ? ??? ??? ?????. JDK8 ? ?? ? ??? ?? ?? (?? ?? 8) ??? ????? ?? ???? ?? ? ??? ?????. 3. ??? ?? ???? ?? ???? ?? equals () ? hashcode () ???? ?? ???????. 4. ?? ?? ??? ???? ?????. ?? ?? ??? ???? ?? ?? (?? 0.75)? ??? ?? ? ???; 5. ?? ?? ??? ??? ??? Multithreaded?? Concu? ???????.
