Java Web¿ª·¢£¬ÄãÒ»¶¨»áÓöµ½
Java Web¿ª·¢ÖУ¬ÓÐÐí¶à¹²Í¨µÄÎÊÌ⣬ÊÇ¿ª·¢ÈËÔ±ÔÚ¿ª·¢¹ý³ÌÖÐÒ»¶¨»áÓöµ½µÄ£¬ÐèÒª´¦ÀíµÄÎÊÌ⣺
1. ÂÒÂëÎÊÌâ
ΪºÎ»á³öÏÖÂÒÂëÎÊÌ⣿¼ÈÈ»ÓÐÂÒÂëÎÊÌ⣬¿Ï¶¨ÊÇÓÉÓÚ±àÂëÉèÖõIJ»Ò»Öµ¼Öµġ£ÔÚWeb¿ª·¢
¹ý³ÌÖУ¬Éæ¼°ÒÔÏÂһЩ±àÂëÉèÖ㬿ͻ§¶Ë²ÎÊýµÄ±àÂëÉèÖã¬Web·þÎñÆ÷µÄ±àÂëÉèÖ㬷þÎñÆ÷¶ËÓ¦ÓóÌÐòµÄ±àÂëÉèÖã¬Êý¾Ý¿âµÄ±àÂëÉèÖõȡ£Ö»ÒªÕâËÄ´¦µÄ±àÂëÉèÖÃ
Óв»ÏàͬµÄ£¬¾Í¿ÉÄÜ»á³öÏÖÂÒÂëÎÊÌâ¡£¿ª·¢ÈËÔ±ÔÚ½øÐпª·¢Ö®Ç°£¬²»·ÀÏÈÁ˽âÒ»ÏÂÕâËĸö±àÂëÔÚÄÄÀïÉèÖ㬵±Ç°×Ô¼ºµÄÏîÄ¿ÉèÖÃÊÇÔõôÑùµÄ£¬ÕâÑù¾Í¿ÉÒԺܺõıÜÃâ
±àÂëÎÊÌâ¡£
2. ȨÏÞ¿ØÖÆ
¶ÔÓÚÒ»¸öJava
Webϵͳ£¬²»ÊÇËùÓеÄÒ³ÃæÓ빦Äܶ¼ÔÊÐíËùÓеÄÓû§·ÃÎʵģ¬ÕâÑù¾ÍÐèÒª¶ÔÓû§ÄÜ·ÃÎÊÄÄЩҳÃæ½øÐпØÖÆÁË¡£Ò»°ãµÄJava
Webϵͳ£¬¶¼ÐèÒª½øÐÐȨÏÞ¿ØÖÆ¡£½øÐÐȨÏÞ¿ØÖƵķ½·¨Óкܶ࣬ÒÔÇ°¿´µ½Óв»ÉÙÏîÄ¿Ö±½ÓÔÚ³ÌÐòÀïдȨÏÞ¿ØÖƵĴúÂ룬ÕâÑùµÄ±×¶ËÊÇÏÔ¶øÒ×¼ûµÄ£¬Ì«²»ÀûÓÚÀ©Õ¹
ÁË£¬Ö»ÒªÓÐÈκεÄÐ޸ģ¬¶¼ÐèÒª¸Ä¶¯Ï൱µÄ´úÂ룬һÊÇÈÝÒ׳ö´í£¬¶þÊÇÐ޸ĵĴú¼Û´ó¡£Ò»¸ö±È½ÏºÃµÄÏë·¨ÊÇ»ùÓÚAOPµÄ˼Ï룬ʹÓÃÀ¹½ØÆ÷À´½øÐÐȨÏÞ¿ØÖÆ£¬µ±È»Ç°
ÌáÊÇϵͳҪÅäÖÃÒ»¶¨µÄÊý¾Ý¿â½á¹¹£¬ÈçÓû§-½ÇÉ«-ȨÏÞ±íÕâÑùµÄ±í½á¹¹¡£µ±È»£¬Ä¿Ç°Óв»ÉÙµÄȨÏÞ¿ØÖÆ¿ªÔ´¿ò¼ÜÈçacegi
3. ²ÎÊýÑéÖ¤
All Input Is
Evil¡£¶ÔÓÚÊäÈë²ÎÊýµÄÑéÖ¤ÊÇÉÙ²»Á˵ġ£¶ÔÓÚ²ÎÊýµÄÑéÖ¤£¬Óпͻ§¶ËÑéÖ¤Óë·þÎñÆ÷¶ËÑéÖ¤£¬Ò»°ãÀ´Ëµ£¬Äܹ»ÔÚ¿Í»§¶Ë½øÐÐÑéÖ¤µÄ£¬ÓÅÏÈ¿¼ÂÇ¿Í»§¶ËÑéÖ¤ÒÔ¼õÉÙ·þ
ÎñÆ÷¶ËѹÁ¦¡£ÏÖÔÚÓÐÐí¶àµÄJavascript¿ò¼Ü¿ÉÒԺܺõÄÍê³ÉÕâÒ»¹¤×÷¡£ÈçJquery Validation²å¼þ¡£
4. Òì³£´¦Àí
Ó¦¸Ã˵¶ÔÓÚÿ¸öϵͳÀ´Ëµ£¬Òì³£´¦Àí¶¼ÊǺÜÖØÒªµÄ¡£µ«ÔÚB/S½á¹¹µÄ»·¾³ÖУ¬Òì³£¾ÍÏԵøü
ΪÖØÒª£¬Ò»¸öÉè¼ÆÁ¼ºÃµÄÒì³£´¦Àí¿ò¼Ü¿ÉÒÔ¼õÉٺܶàµÄ´úÂë±àд¹¤×÷¡£
5. ²ÎÊý´«µÝ
ÔÚB/S½á¹¹£¬»ùÓÚHTTPÀ´Íê³ÉͨÐÅ£¬Ã¿Ò»´ÎµÄ¿Í»§¶ËÓë·þÎñÆ÷¶ËµÄ½»»¥¶¼ÊÇÒ»´Î²ÎÊý´«
µÝµÄ¹ý³Ì¡£¿ØÖƲÎÊýµÄ´«µÝ¹ý³Ì¾ÍÏԵúÜÖØÒªÁË¡£ÒªÇå³þµÄÖªµÀÿһ´ÎµÄB/SµÄ½»»¥£¬ÐèÒª´«µÝÄÄЩ²ÎÊý£¬ÄÄЩ²ÎÊýÊǺϷ¨µÄ£¬ÄÄЩ²ÎÊýÊDz»ºÏ·¨µÄ£¬ÊÇͨ¹ý
GET·½Ê½»¹ÊÇͨ¹ýPOST·½Ê½£¬»¹ÊÇͨ¹ýURLÁ´½ÓµÄ·½Ê½¡£
6. Ajax
ÏÖÔÚµÄJava
Webϵͳ£¬²»Ê¹ÓÃAjax¼¼ÊõÊDz»¿ÉÄܵÄÁË¡£AjaxʵÔÚÊÇÒ»Ïî²»´íµÄ¼¼Êõ£¬²»Ë¢ÐÂÒ³Ãæ¶øÍê³ÉÓë·þÎñÆ÷¶ËµÄͨÐÅ£¬ËüʹµÃ»ùÓÚB/SµÄ½á¹¹¹¦ÄܸüÇ¿´óÁË£¬
Ðí¶à´«Í³µÄWebÓ¦ÓóÌÐòËùÎÞ·¨Íê³ÉµÄ¹¦ÄÜÏÖÔڴ󶼿ÉÒÔÓÃB/S¼Ü¹¹À
Ïà¹ØÎĵµ£º
ÎÒºÜϲ»¶Ñ§Ï°java£¬ÄÇÊÇÔÚÎÒÕýʽÉÏÁËÕâ¸ö¿Îºó¾Íϲ»¶ÉÏÁË£¬ÎÒ¾õµÃÎÒѧµÄÖ»ÊÇÒ»°ã£¬µ«ÊÇÎÒÏë°ÑÎÒµÄһЩ¸öÈ˾ÑéдÏÂÀ´£¬ºÇºÇ¡£¡£¡£¡£¡£
javaÊÇÃæÏò¶ÔÏóµÄ±à³ÌÓïÑÔ£¬ÎÒÒÔÇ°Ö»Êdzõ²½Ñ§Ï°¹ýc£¬Ñ§Ï°javaʱһЩ»ù±¾µÄÓï·¨Ö»ÊÇ¿´ÁË¿´£¬ÒòΪºÍcÊDz¶àµÄ£¬µ«ÊǺóÀ´²»¶ÏµØѧϰ·¢ÏÖ¡£Ñ§Ï°javaÒªºÃºÃÊìϤ¸÷ÖÖ¸÷ÑùµÄÀֻ࣬Ҫ½«¸÷ÖÖÀàÊì ......
Àà¼ÓÔØÆ÷ÊÇ Java ÓïÑÔµÄÒ»¸ö´´Ð£¬Ò²ÊÇ Java ÓïÑÔÁ÷ÐеÄÖØÒªÔÒòÖ®Ò»¡£ËüʹµÃ Java Àà¿ÉÒÔ±»¶¯Ì¬¼ÓÔص½ Java ÐéÄâ»úÖв¢Ö´ÐС£Àà¼ÓÔØÆ÷´Ó JDK 1.0 ¾Í³öÏÖÁË£¬×î³õÊÇΪÁËÂú×ã Java Applet µÄÐèÒª¶ø¿ª·¢³öÀ´µÄ¡£Java Applet ÐèÒª´ÓÔ¶³ÌÏÂÔØ Java ÀàÎļþµ½ä¯ÀÀÆ÷Öв¢Ö´ÐС£ÏÖÔÚÀà¼ÓÔØÆ÷ÔÚ Web ÈÝÆ÷ºÍ OSGi Öеõ½Á˹㷺µÄʹÓá ......
²Ù×÷·û
1.λ²Ù×÷·û
(a) >>>ÓÒÒÆ£¬¸ßλÓÃ0Ìî³ä£»
int a = 14;
int b = 2;
System.out.println(a >>> b);// 3
int c = -14;
int d = 2;
System.out.println(c >>> d);// 1073741820
(b) >>·ûºÅλ²»±ä£¬ÆäËûλÓÒÒÆ£¬¸ßλÓÃ0Ìî³ä£¬Æä½á¹ûÓëa/2bÏàͬ£»
int a = 14;
int b = 2;
Sy ......
ÏÂÔصØÖ· ¿ÉÒÔÔÚeclpseÖÐÅܵÄ
Éú²úexcelÓ¦Óãº
package com.lihp.exl;
/**
Ä¿µÄ£ºÌṩÓÉÊý¾Ý¶ÔÏ󼯺ÏÀࣨVector£©Éú³ÉExcel¹¤×÷±íµÄ¹¦ÄÜ
×÷Õߣºlihaipeng
*/
import java.io.*;
import java.util.*;
import java.lang.reflect.Method;
import org.apache.poi.hssf.usermodel.HSSFSheet;
impor ......
ÿ¸öJava³õѧÕ߶¼Ó¦¸ÃÃ÷°×µÄÎÊÌâ
¶ÔÓÚÕâ¸öϵÁÐÀïµÄÎÊÌ⣬ÿ¸öѧJavaµÄÈ˶¼Ó¦¸Ã¸ã¶®¡£µ±È»£¬Èç¹ûÖ»ÊÇѧJavaÍæÍæ¾ÍÎÞËùνÁË¡£Èç¹ûÄãÈÏΪ×Ô¼ºÒѾ³¬Ô½³õѧÕßÁË£¬È´²»ºÜ¶®ÕâЩÎÊÌ⣬Ç뽫Äã×Ô¼ºÖعé³õѧÕßÐÐÁС£ÄÚÈݾùÀ´×ÔÓÚCSDNµÄ¾µäÀÏÌù¡£
¡¡¡¡ÎÊÌâÒ»£ºÎÒÉùÃ÷ÁËʲô£¡
String s = "Hello world!";
¡¡¡¡Ðí¶àÈ˶¼×ö¹ýÕâÑùµÄ ......