Javaï¼Servletã®è¦ãã¦ããããåºç¤é ç®
Javaï¼Servletã使ã£ã¦ããã°ã©ãã³ã°ããå ´åã«è¦ãã¦ããããåºç¤é ç®ããªã¹ãã¢ãããã¾ããã
ç®æ¬¡
å ¥åºåå¦ç
ãã¡ã¤ã«å ¥åºå
(1). ããã¹ããã¡ã¤ã«ããã®èªã¿è¾¼ã¿ 以ä¸ãçµã¿åãããã ã»java.io.FileReaderã¯ã©ã¹ ã»java.io.BuffuredReaderã¯ã©ã¹ (2). ããã¹ããã¡ã¤ã«ã¸ã®åºå 以ä¸ãçµã¿åãããã ã»java.io.FileWriterã¯ã©ã¹ ã»java.io.BufferedWriterã¯ã©ã¹ ã»java.io.PrintWriterã¯ã©ã¹
ãã°åºå
ãã¾ãã¾ãªã©ã¤ãã©ãªãåå¨ããã ã»Java Logging API(java.util.loggingããã±ã¼ã¸) ã»Log4j ã»Jakarta Commons Logging ã»SLF4J
DBã¢ã¯ã»ã¹(JDBC)
(1). DBã¸æ¥ç¶ java.sql.DriverManager#getConnection() (2). DBããåæ java.sql.Connection#close() (3). SQLå®è¡ç¨ãªãã¸ã§ã¯ãåå¾ java.sql.Connection#createStatement() (4). selectæå®è¡ java.sql.Statement#executeQuery() (5). selectæã®çµæã»ãã java.sql.ResultSetã¯ã©ã¹ (6). insert/update/deleteæå®è¡ java.sql.Statement#executeUpdate()
ç·¨éå¦ç
åºæ¬çãªãã¼ã¿æ§é
(1). é å ã»é åã®çæ ã»é åã¸ã®ãã¼ã¿æ ¼ç´ ã»é åããã®ãã¼ã¿åå¾ ã»é åã¸ã®ç¹°ãè¿ãå¦ç (2). java.util.List ã»java.util.Listã®çæ ã»java.util.Listã¸ã®ãã¼ã¿æ ¼ç´ ã»java.util.Listããã®ãã¼ã¿åå¾ ã»java.util.Listã¸ã®ç¹°ãè¿ãå¦ç(foræ) (3). java.util.Map ã»java.util.Mapã®çæ ã»java.util.Mapã¸ã®ãã¼ã¿æ ¼ç´ ã»java.util.Mapããã®ãã¼ã¿åå¾ ã»java.util.Mapã¸ã®ç¹°ãè¿ãå¦ç(for-eachæ) (4). Bean ã»setterã¨getter
ã¡ã¢ãªä¸ã®ãã¼ã¿æä½
(1). 1件ã®ãã¼ã¿ã®ã¡ã¢ãªã¸ã®æ ¼ç´ ï¼ä»¶ã®ãã¼ã¿ã¯ä»¥ä¸ã®ããããã«æ ¼ç´ããã ã»java.util.Mapã«æ ¼ç´ããã ã«ã©ã åããã¼ã¨ãã¦å¤ãæ ¼ç´ããã ã»ãã¼ã¿ã«åããã¦ä½æããBeanã«æ ¼ç´ããã ã«ã©ã åã®setter/getterãä½æããã (2). è¤æ°ä»¶ã®ãã¼ã¿ã®ã¡ã¢ãªã¸ã®æ ¼ç´ è¤æ°ä»¶ã®ãã¼ã¿ã¯ä»¥ä¸ã®ããããã«æ ¼ç´ããã ã»ãã¼ã¿ä»¶æ°åä½æããjava.util.Mapã java.util.Listã«æ ¼ç´ããã ã»ãã¼ã¿ä»¶æ°åä½æããBeanã java.util.Listã«æ ¼ç´ããã ã»ãã¼ã¿ä»¶æ°åä½æããBeanãé åã«æ ¼ç´ããã (3). è¤æ°ä»¶ã®ãã¼ã¿ã®åºæ¬çãªæä½ foræã§ç¹°ãè¿ãã¦ï¼ä»¶ãã¤å¦çããã (4). è¤æ°ä»¶ã¬ã³ã¼ãã®é«åº¦ãªæä½ ä»¥ä¸ã®æä½ã«æ £ããã¨ããã æ½åºãã½ã¼ããçµåãéè¨
æååç·¨é
(1). çµå +æ¼ç®å StringBufferã¯ã©ã¹ (2). åå² java.lang.String#split() (3). ç½®æ java.lang.String#replaceFirst() java.lang.String#replaceAll() (4). åãåºã java.lang.String#substring() (5). æ¤ç´¢ java.lang.String#indexOf()
æ°å¤ç·¨é
(1). ååæ¼ç® +ã-ã*ã/ã%æ¼ç®å (2). 10é²æ° java.math.BigDecimalã¯ã©ã¹ (3). æ°å¤âæåå java.text.NumberFormat#parse() java.text.NumberFormat#format()
æ¥ä»ç·¨é
(1). æ¥ä»æ å ±ã®ä¿æ java.util.Dateã¯ã©ã¹ (2). æ¥ä»ã®æä½ java.util.Calendarã¯ã©ã¹ (3). æ¥ä»âæåå java.text.SimpleDateFormat#parse() java.text.SimpleDateFormat#format()
Webé¢é£å¦ç
HTTPæä½
(1). HTTPãªã¯ã¨ã¹ããããã®åå¾ javax.servlet.http.HttpServletRequest#getHeader() (2). HTTPãªã¯ã¨ã¹ããã©ã¡ã¼ã¿ã®åå¾ javax.servlet.http.HttpServletRequest#getParameter() (3). HTTPã¬ã¹ãã³ã¹ãããã®è¨å® javax.servlet.http.HttpServletResponse#setHeader() (4). HTTPã¬ã¹ãã³ã¹ããã£ã®åºå(HTMLçã®åºå) javax.servlet.http.HttpServletResponse#getWriter() åå¾ããWriterã«å¯¾ãã¦println() (5). ã¹ãã¼ã¿ã¹ã³ã¼ãã®è¨å® javax.servlet.http.HttpServletResponse#setStatus()
ã»ãã·ã§ã³æä½
(1). ã»ãã·ã§ã³ã®åå¾ javax.servlet.http.HttpServletRequest#getSession() (2). ã»ãã·ã§ã³ã¸ã®ãã¼ã¿æ ¼ç´ javax.servlet.http.HttpSession#setAttribute() (3). ã»ãã·ã§ã³ããã®ãã¼ã¿åå¾ javax.servlet.http.HttpSession#getAttribute() (4). ã»ãã·ã§ã³ããã®ãã¼ã¿åé¤ javax.servlet.http.HttpSession#removeAttribute()
åèURL
é¢é£è¨äº
- Javaã使ããªãå¿ ãè¦ãã¦ãããããã¼ã¿æ§é - é åã»ãªã¹ãã»ããã
- Javaã使ããªãç解ãã¦ããããã¢ã«ã´ãªãºã - æ½åºã»ã½ã¼ãã»çµåã»éè¨ (ãªã¹ãï¼ãããç·¨)
- Javaã使ããªãç解ãã¦ããããã¢ã«ã´ãªãºã - æ½åºã»ã½ã¼ãã»çµåã»éè¨ (ãªã¹ãï¼ãã¼ã³ç·¨)
- BigDecimalã®ä»çµã¿ãå³è§£ãã¦ã¿ãã
- BigDecimalã®ä»çµã¿ãå©ç¨ãã¦ã¿ãã