Newer
Older
test-sample / src / main / java / com / example / testsample / SampleController.java
yhornisse on 9 Oct 2023 622 bytes add test sample
package com.example.testsample;

import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("sample")
public class SampleController {

  private final SampleAppService sampleService;

  public SampleController(final SampleAppService sampleService) {
    this.sampleService = sampleService;
  }

  @GetMapping
  public ResponseEntity<SampleResponse> get() {
    return ResponseEntity.ok(sampleService.hoge());
  }
}