This domain may be for sale!
JavaBeansã®ããããã£ã¨ã«ãã»ã«å ååã¯ãJavaBeansã³ã³ãã¼ãã³ãã¨ãã¦æ±ããJavaã¯ã©ã¹ã®æ¡ä»¶ã¨ãã¦ã以ä¸ã®3ã¤ã®ã«ã¼ã«ã示ãã¾ããã ä»åã¯ããããã®ã«ã¼ã«ã®ãã¡ããããããã£ãã¨ã¯ä½ãã説æãã¾ããã¡ãªã¿ã«ããã¤ãã³ããããã³ãã¡ã½ãããã®ã«ã¼ã«ã¯ã主ã«JavaBeansãGUIéçºã«ç¨ããå ´åã«éè¦ã¨ãªããã®ã§ãããJSPéçºãªã©ã®ãµã¼ããµã¤ãã§ç¨ãããããã¨ã¯ã»ã¨ãã©ããã¾ããããã£ã¦ãæ¬é£è¼ã§ã¯ããã2ç¹ã«ã¤ãã¦ã®è©³ãã説æãçç¥ãããã¨æãã¾ãã ããããã£ã¨ã¯ãJavaBeansã®å±æ§ã表ããã®ã§ããä¸è¨ã§ããã°ããJavaã¯ã©ã¹ã®ãã£ã¼ã«ãï¼ã¤ã³ã¹ã¿ã³ã¹å¤æ°ï¼ãã«ãã»ã«åãããã®ãã§ãã ããã§ä¾ãã°ãååå¨åº«ã表ãJavaBeansãZaikoãã以ä¸ã®ããã«å®ç¾©ããã¨ãã¾ãããã
ããããã¯ã©ã¹ã©ã¤ãã©ãªæ´»ç¨ç·¨ã大詰ãã®ä»åã¯ããã¼ã¿ãã¼ã¹ç·¨ãã§ãããªãã¨ãã£ã¦ãããµã¤ãã«ãã¾ãã¾ãªå¯è½æ§ãä¸ããé«åº¦ãªãã¼ã¿å¦çãæ¯ããã®ã¯ãã¼ã¿ãã¼ã¹ãµã¼ããããã¦ã»ãã«ããã¾ããã ãã£ã¨ãããã¼ã¿ãã¼ã¹é£æºã ããã¨ãã£ã¦æ±ºãã¦ãã¾ãããã¨ã¯ããã¾ãããæ¬ç¨¿ãã覧ããã ããã°ãã£ã¨ãç解ããã ããããã«ããã¼ã¿ãã¼ã¹é£æºãå¸ãjava.sqlããã±ã¼ã¸ï¼JDBCï¼ã®ç¨æ³ã¯ãããã¾ã§ã¨ãªããå¤ãããã¨ãªãã極ãã¦å®åçã§ããããã¤ãã®å®ç³çãªã¢ã«ã´ãªãºã ãããæ¼ããã¦ãã¾ãã°ã8å²æ¹ã®ç¨éã¯ååã«æºãããã¯ãã§ãããã¼ã¿ãã¼ã¹ã¯æ±ºãã¦é£ãããã®ã§ã¯ããã¾ããã ãã ãããä¸å®éãè¶ ãããã¼ã¿ã®æä½ã«å¯¾ãã¦å¸¸ã«ããã©ã¼ãã³ã¹ãç¶æããããã«ã¯ããã¯ããããªãã®ãã¯ããã¯ãæ±ããããã§ããããããããã¼ã¿ãã¼ã¹é£æºããã°ã©ãã³ã°ã«é£ããç¹ãããã¨ãããããã®æã ã®ããã«ããã¯ãé©åã«æ
ããã¾ã§10åã«ããã£ã¦ãJSPï¼Java Server Pagesï¼ããã¼ã¹ã¨ããã³ã¼ãã£ã³ã°ã®ææ³ã«ã¤ãã¦å¦ç¿ãã¦ãã¾ãããããã¾ã§é ã«èªã¿é²ãã¦ããããæ¹ãªãã°ãJSPéçºãæ軽ã§ãããªãããããã«å¼·åãªã¢ã¼ããã¯ãã£ãæä¾ãã¦ããã®ãããã£ã¨ãåããã«ãªãããã¯ãã§ãã ãããããããªãã°ããã¹ã¦ã®ãµã¼ããµã¤ãã¢ããªã±ã¼ã·ã§ã³ã¯JSPã§è¨è¿°ãã¹ãããªã®ã§ãããããçãã¯ã¯ã£ããã¨ãå¦ãã§ãã 第1åããµã¼ãã¬ããï¼JSPã®å½¹å²ãç解ãããã§ãç´¹ä»ããããã«ãJSPã¨ã¯æ±ºãã¦ãµã¼ãã¬ããã®ãå¾ç¶ãæè¡ã§ã¯ããã¾ããããµã¼ãã¬ããã®åé¡ç¹ã解決ãã¹ãç»å ´ããæè¡ã§ãããã¨ã¯ééãããã¾ããããããã«ãã£ã¦ãJSPã«ãµã¼ãã¬ãããç½®ãæãããã¨ãããã®ã§ã¯ãªãããJSPã¨ãµã¼ãã¬ããã¨ãããããã®å¾æåéã«å¿ãã¦ãæè¡ã使ãåããé¸æè¢ãä¸ãããããã¨èããã®ãæ£ããã¨ããæ¹ã¨ããã¾ãã
ï¼1ï¼æååã®ç½®æå¦ç ååã¾ã§ã§ãå ±æããã¯ãã¼ã¯ã®åºæ¬çãªæ©è½ã¯ä¸éããããã¾ãããããã§ãåé¡ãªããµã¼ãã¹éå§ãã¨ãããã¨ããã§ããããã®åã«è¡ãã¹ãå¦çãããã¾ãã ããã¾ã§ã¯ã¦ã¼ã¶ãå ¥åããæååã®ãã§ãã¯ãè¡ããã«ããã®ã¾ã¾HTMLæã¸ã®åºå ãSQLæã®ä½æã«ä½¿ç¨ãã¦ãã¾ãããããã¾ã§ã®ä¾ã§ä½¿ç¨ããæååã«ã¯ãã¾ãã¾<ã>ãã·ã³ã°ã«ã¯ãªã¼ãâ'âãå«ã¾ãã¦ãã¾ããã§ããããããã¦ã¼ã¶ã¼ããããã®æååãå«ãå 容ãç»é²ãããã¨èããå ´åããã¼ã¸ã®ãã¶ã¤ã³ãå´©ããããSQLæã®å®è¡ã§ã¨ã©ã¼ãåºãããã¦ãã¾ãã¾ããã¾ããã¦ã¼ã¶ã¼ãæªæãæã£ã¦ããå ´åã« ã¯ããã¼ã¿ã®æ¹ãããç ´å£ãªã©ãç®çã¨ããæååããã©ã¡ã¼ã¿ã¨ãã¦æ¸¡ããããã¨ãèãããã¾ãããããã¯ãé大ãªã»ãã¥ãªãã£ã¼ãã¼ã«ã§ãããããç¹ã«ãã©ã¡ã¼ ã¿ã¨ãã¦æ¸¡ãããå¤ã®æ±ãã«ã¯æ³¨æãå¿ è¦ã§ãã ããã§ãå ¥åãããæååãé©åã«
ååã¯ãJSPãããã¼ã¿ãã¼ã¹ã«ã¢ã¯ã»ã¹ããæ¹æ³ãç´¹ä»ãã¾ãããä»åã¯ãããå ·ä½çãªä¾ã¨ãã¦ãå®éã«JSPã¨ãã¼ã¿ãã¼ã¹ãé£æºãããç°¡åãªWebã¢ããªã±ã¼ã·ã§ã³ãä½æãã¦ã¿ã¾ããä¾ã¨ãã¦åãä¸ããWebã¢ããªã±ã¼ã·ã§ã³ã¯ããªã³ã©ã¤ã³ã§åºæ¬ ã®ç»é²ã¨ç¢ºèªãè¡ããã¨ãã§ãããåºæ¬ 表ã¢ããªã±ã¼ã·ã§ã³ã§ãããã¼ã¿ãã¼ã¹ã¸ã®ã¢ã¯ã»ã¹ãè¡ãåºæ¬çãªé¨åã¯ãååç´¹ä»ããæ¹æ³ã使ç¨ãã¦ãã¾ãã åºæ¬ ç»é²ã¢ããªã±ã¼ã·ã§ã³ãä½æãã¦ã¿ã Webã¢ããªã±ã¼ã·ã§ã³ãä½æããä½æ¥ã®æµããç解ããããã«ããã¤ãã¨ã¯èª¬æã®é çªãå¤ãã¦ãä»åä½æããåºæ¬ 表ã¢ããªã±ã¼ã·ã§ã³ãæåã«è¦ã¦ã¿ã¾ãããã ä½ãç»é²ããã¦ããªãç¶æ ã§ã¯ã次ã®ããã«åã¡ã³ãã¼ã«åå¥ã®åºæ¬ ç»é²ãã©ã¼ã ã表示ããã¾ããããããã®ã¡ã³ãã¼ããèªåã®æ¬ã®ãã©ã¼ã ã§åºå¸ã¨æ¬ å¸ã®ã©ã¡ãããé¸æããã³ã¡ã³ãæãå ¥åãã¦ãç»é²ããè¡ãã¾ãã
Strutsã©ã¸ãªã¿ã°ã®å¿ç¨ 表ï¼è¡æ°ãä¸å®ã®ãã¼ãã«ï¼ã®ä¸ã®ã©ã¸ãªãã¿ã³ è¡æ°ãå¯å¤ã®è¡¨ã«ããã¦ãã»ã«ã®ä¸ã«ã©ã¸ãªãã¿ã³ãé ç½®ããæ¹æ³ã ãµã³ãã« ï¼è¡ã®æ å ±ãä¿æãããµããã©ã¼ã ãä½ãã主ãã©ã¼ã ããã¯ã¤ã³ããã¯ã¹ã§ãµããã©ã¼ã ãåå¾ããgetterãç¨æããã JSPå ã§ã¯logic:iterateãã¤ã³ããã¯ã¹ä»ãã§ä½¿ç¨ãã©ã¸ãªãã¿ã³ããã¤ã³ããã¯ã¹ãæå¹ãã¨ããæå®ã«ããã jspï¼ <table border="1"> <logic:iterate name="mainForm" property="charactor" scope="request" id="charactor" indexId="index1"> <tr> <td> <bean:write name="charactor" property="name" filter="false"/> </td> <td
JavaBeansã®å½¹å² JavaBeansãå ã®2æè¡ã¨ç°ãªãç¹ã¨ã¯ããµã¼ãã¬ããã»JSPãããããããµã¼ããµã¤ãã§ã®ç¨éããåæã¨ããæè¡ã§ããã®ã«å¯¾ããJavaBeansã¯å¿ ãããããµã¼ããµã¤ãç¨éãã«éãããæè¡ã§ã¯ãªãã¨ããç¹ã§ãã JavaBeansã¯åå©ç¨ãããã¨ãç®çã¨ãã¦ä½æãããï¼ã¨ãããã¨ã¯ãæ±ç¨çãªãã¸ãã¯ãå®è£ ããï¼Javaã¯ã©ã¹ã§ããããèªä½ãç´æ¥ã«ã¯ã©ã¤ã¢ã³ãããå¼ã³åºããããã¨ã¯ããã¾ããã ãµã¼ãã¬ããããããã¯JSPããå¼ã³åºããããã¨ã«ãã£ã¦ããã¼ã¿ãã¼ã¹ã¸ã®æ¤ç´¢ãæ´æ°ããã¡ã¤ã«å¦çãªã©ã®ãããããå®ãããããæ¯è¼çãæ±ç¨çãªããã¸ãã¹ãã¸ãã¯ã®å¦çãè¡ããå¿ è¦ã«å¿ãã¦å¦ççµæãè¿ããããã¯é¨åã§ãããã¾ãã ãªã¹ã3ã¯ãJSPããµã¼ãã¬ããããå¼ã³åºããããã©ã¡ã¼ã¿ã¨ãã¦æ¸¡ããã人åã«å¯¾ãã¦ããHello,æ¥å°¾åãã®ãããªã¡ãã»ã¼ã¸ãè¿ãã極ãã¦ã·ã³
ã覧ããã ããããã«ãSQLã¤ã³ã¸ã§ã¯ã·ã§ã³æ»æã®ãã¤ã³ãã¯ã·ã³ã°ã«ã¯ã©ã¼ãã'ãã使ã£ã¦æååå®æ°ã®ä¸ããè±åºããSQLæã®æ§æã«å½±é¿ãããã¼ããã¨ã§ããããããã£ã¦ãããã«å¯¾å¦ããã«ã¯ã¦ã¼ã¶ãå ¥åããã·ã³ã°ã«ã¯ã©ã¼ããæååã®åºåãã¨ãã¦æ©è½ãããªããã¨ã ãããããã¨ã¹ã±ã¼ãå¦çãã¨å¼ã¶ã SQLæã®ææ³ã§ã¯ãæååå®æ°ä¸ã§ã·ã³ã°ã«ã¯ã©ã¼ãã'ãã2å並ã¹ãã¨ããã1åã®ã·ã³ã°ã«ã¯ã©ã¼ããã®ãã®ã表ãã¨ããç´æã«ãªã£ã¦ããããã¨ãã°æ¬¡ã®ãããªè¡¨è¨ãããã¨ããã
JSPã®ã¢ã¯ã·ã§ã³ã®ä½ç½®ä»ã ä»åã¯ãJSPã®ãã¢ã¯ã·ã§ã³ãã«ã¤ãã¦èª¬æãã¾ããåå説æããã¹ã¯ãªããããJSPãã¼ã¸ã«åãè¾¼ã¾ããJavaã³ã¼ããå®è¡ããããã®ã¿ã°ãã§ããã®ã«å¯¾ããã¢ã¯ã·ã§ã³ã¯ãJSPãã¼ã¸ããå¤é¨ã®Javaã³ã¼ããå¼ã³åºãããã®ã¿ã°ãã§ãã åå説æããã¨ãããç¾å¨ã®JSPéçºã§ã¯ãWebã¢ããªã±ã¼ã·ã§ã³å ¨ä½ã®æ©è½ããMVCï¼Model View Controllerï¼ã¢ãã«ãã«å¾ã£ã¦3åå²ããææ³ã主æµã§ãããã®MVCã¢ãã«ã§ã¯ããã¸ãã¹ãã¸ãã¯ã®å®è¡ãé常ã®Javaã¯ã©ã¹ï¼Modelï¼ã«ä»»ãããã®å®è¡çµæãJSPãã¼ã¸ï¼Viewï¼ã§è¡¨ç¤ºããã¨ããå½¹å²åæ ãè¡ãã¾ãããã®ãããJSPãã¼ã¸ã®å é¨ã«Javaã³ã¼ããåãè¾¼ãã¹ã¯ãªããã¯ãæè¿ã§ã¯ãã¾ãå©ç¨ãããªããªãã¾ããã ãã®ä»£ããã«ãâãã¾ã©ãâã®JSPãã¼ã¸ã§ã¯ã¢ã¯ã·ã§ã³ãå¤ç¨ãã¾ãããã®ã¢ã¯ã·ã§ã³ãç¨ãã¦ãã
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}