Implementing the Order Management API controller
The Order Management API will follow the same architecture and package structure used in the Product API, so the controllers will be created within the adapter.inbound.rest
package.
The first step is to create the OrderManagementApiController
class, implementing the methods of the OrderManagementApi
interface. Here is a sample of the code:
@Controller
public class OrderManagementApiController implements OrderManagementApi {
@Override
public ResponseEntity<List<OrderResponse>> ordersGet() {
//Add your own concrete implementation
return OrderManagementApi.super.ordersGet();
}
@Override
public ResponseEntity<Void> ordersDelete(String orderId) {
//Add your own concrete implementation
return OrderManagementApi.super.ordersDelete(orderId);
}
@Override
public ResponseEntity<OrderResponse> ordersOrderIdGet(String orderId)
{
//Add your...