SampleController.java ( void )
페이지 정보
![profile_image](https://dancepkt.cafe24.com/data/member_image/ad/admin.gif?1630310007)
본문
package com.pkt.controller;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import lombok.extern.log4j.Log4j;
@Controller
@RequestMapping("/sample/")
@Log4j
public class SampleController {
// void가 리턴 타입일 경우
@GetMapping("")
public void basic() {
log.info("sample.jsp ...");
// sample.jsp 찾는다.
}
@GetMapping("aa")
public void basic01() {
log.info("/sample/aa.jsp ...");
// /sample/aa.jsp 찾는다.
}
}
- 이전글① 기초적인 컨트롤러 생성 실습 ( 리턴 타입 ) 24.07.16
- 다음글SimpleController.java ( String , 변수 전달 ) 24.07.16
댓글목록
등록된 댓글이 없습니다.