Class HomeController
java.lang.Object
com.bayudwiyansatria.spring.controller.HomeController
HomeController
This class handles HTTP requests for the home endpoint. It is annotated with
@RestController
to indicate that it is a Spring MVC controller. It is also annotated with
@Slf4j
to enable logging.
The getUserById
method handles HTTP GET requests to the root endpoint.
- Since:
- 0.0.1
- Version:
- 0.0.1
- Author:
- Bayu Dwiyan Satria
-
Constructor Summary
ConstructorsConstructorDescriptionHomeController
(HomeService homeService) Constructs a new HomeController with the specified HomeService. -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<Response>
Handles HTTP GET requests to the root endpoint.
-
Constructor Details
-
HomeController
Constructs a new HomeController with the specified HomeService.- Parameters:
homeService
- the HomeService to be used by this controller- Since:
- 0.0.1
-
-
Method Details
-
getUserById
Handles HTTP GET requests to the root endpoint. This method returns a ResponseEntity containing a Response object.- Returns:
- a ResponseEntity with a Response object
- Since:
- 0.0.1
-