ä»åã¯SpringMVCã使ã£ã¦ç°¡åãªç»é¢é·ç§»ã¢ããªã±ã¼ã·ã§ã³ãä½ã£ã¦ã¿ã¾ããã
以ä¸ã®ãã¼ã¸ããµã³ãã«ã»ã¢ããªã±ã¼ã·ã§ã³åèã«ãã¾ããã
第4å SpringMVCã®åºæ¬ãç¥ã - ä»å¿
è¦ãªäººã®ããã®éç¿ Spring Frameworkï¼ITpro
èºããã¨ãããç®æ¡æ¸ã
ã»input.jspãä½ã£ãã¨ãã«æåã®2è¡ã®taglibã®ã¨ãããã¨ã©ã¼ã«ãªã£ãã
"http://java.sun.com/jsp/jstl/core" ã®ã¿ã°ã»ã©ã¤ãã©ãªã¼è¨è¿°åãè¦ã¤ããã¾ãã "http://www.springframework.org/tags/form" ã®ã¿ã°ã»ã©ã¤ãã©ãªã¼è¨è¿°åãè¦ã¤ããã¾ãã
âstanderd.jarããã«ããã¹ã«å ãããsunã®æ¹ã®ã¨ã©ã¼ã¯æ¶ãã¾ããã
å¥ã«åçWebããã¸ã§ã¯ãã®å ´åãã«ããã¹ã«è¿½å ããªãã¦ãWEB-INF/libã«ç½®ããæç¹ã§
[ã©ã¤ãã©ãªã¼]â[WebAppã©ã¤ãã©ãªã¼]
ã®ã¨ããã«ããã¿ãããªã®ã§å¿
è¦ãªãæ°ãããã®ã§ããããã
ãã®è¾ºã®ä»çµã¿ã¯ã¾ã ããããã£ã¦ãã¾ããã
âspringã®ã»ãã®ã¨ã©ã¼ã¯ãªããªãæ¶ãã¦ãããªãã®ã§ããµã³ãã«ãã¼ã¸ã¨åãverã®spring2.0.6ã®jarã使ç¨ãã¦ãã«ããã¹ã«è¿½å ãããæ¶ãã¾ãããï¼ã¨ã©ã¼ãåºãã¨ãã®verã¯2.5.6ï¼
ãã®ãã¨jarãå
ã®ãã¼ã¸ã§ã³ã«æ»ãã¦ããªããã¨ã©ã¼ã¯ããããªããªã£ãã®ã§ããã®ã¾ã¾2.5.6ã使ããã¨ã«ã
â»ãã®ç¶æ
ã®2.5.6verã ã¨formã¿ã°ã®ã¨ããã«
ä¸æãªã¿ã° (form:form) ã§ãã
ã¨ããè¦åã¡ãã»ã¼ã¸ãåºã¾ãããã¨ãããããã¾ãã¯åã模æ§ã
ã»ExampleController.javaãæ¸ãã¦ããã¨ãã«SimpleFormControllerãè¦ã¤ãããªãã
âorg.springframework.web.servlet.mvc.SimpleFormControllerã¯Spring2.5.6ã§ã¯spring.jarã§ã¯ãªããspring-webmvc.jarã«ãã模æ§ãdist/modulesã«ããã®ã§ã³ãã¼ãã¦è¿½å ã
åèï¼Springã使ç¨ããã«ã¯ï¼ï½Java Springã®éå¼ãã¡ã¢
ã»eclipseã®tomcatãã¿ã³ãæ¼ãã¦ãã¢ããªã±ã¼ã·ã§ã³ãèªèãããªãã
âããã¯å®å
¨ã«ãµã³ãã«ãã¼ã¸ã®ç¢ºèªãã¹ã
[ãµã¼ãã¼]ã¦ã¤ã³ãã¦ããèµ·åããªãã¨ãããªãã¿ããã§ãã
ãã¡ããã¨ç¢ºèªãããï½ï¼ãã¨ãã話ã
ãããªãããªãããã¾ãã¦ããã£ã¨ã®ãããã¾ã³ããè¿ãç»é¢é·ç§»ã¢ããªãå®æãã¾ããã
ãæè¦æéç´3æé
javaã®ã¢ããªã¯æ¬å½ã«åããã¾ã§ã®æºåã大å¤ã§ãã
ï¼ä»ã®è¨èªã¯ãã£ããã¨ãªãã§ããâ¦ï½ï¼