Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

´«ÖDz¥¿Íjavaѧϰ4

½ñÌìÎÒѧϰÁË·´ÉäÓë¶àÏ̵߳Ä֪ʶ
 
·´É䣺Class cls1=Date.class//×Ö½ÚÂë1£»
         Class cls2=Person.class//×Ö½ÚÂë2£»
 
P1.getClass();//µÃµ½×Ö½ÚÂë
Class.forName(“java.lang.String”) //µÃµ½Õâ¸öÀàµÄ×Ö½ÚÂë
 
ºǫ́Ïß³ÌÓëÁªºÏÏß³Ì
l         Èç¹ûÎÒÃǶÔij¸öÏ̶߳ÔÏóÔÚÆô¶¯£¨µ÷ÓÃstart·½·¨£©Ö®Ç°µ÷ÓÃÁËsetDaemon£¨true£©·½·¨£¬Õâ¸öÏ߳̾ͱä³ÉÁ˺ǫ́Ï̡߳£
l         ¶ÔJava³ÌÐòÀ´Ëµ£¬Ö»Òª»¹ÓÐÒ»¸öǰ̨Ïß³ÌÔÚÔËÐУ¬Õâ¸ö½ø³Ì¾Í²»»á½áÊø£¬Èç¹ûÒ»¸ö½ø³ÌÖÐÖ»Óкǫ́Ïß³ÌÔËÐУ¬Õâ¸ö½ø³Ì¾Í»á½áÊø¡£
l         pp.join£¨£©µÄ×÷ÓÃÊÇ°ÑppËù¶ÔÓ¦µÄÏ̺߳ϲ¢µ½µ÷ÓÃpp.join£¨£©£»Óï¾äµÄÏß³ÌÖС£
 
ʹÓÃRunnable½Ó¿Ú´´½¨¶àÏß³Ì
l         Êʺ϶à¸öÏàͬ³ÌÐò´úÂëµÄÏß³ÌÈ¥´¦Àíͬһ×ÊÔ´µÄÇé¿ö£¬°ÑÐéÄâcpu£¨Ị̈߳©Í¬³ÌÐòµÄ´úÂë¡¢Êý¾ÝÓÐЧ·ÖÀ룬½ÏºÃµØÌåÏÖÁËÃæÏò¶ÔÏóµÄÉè¼Æ˼Ïë¡£
l         ¿ÉÒÔ±ÜÃâÓÉÓÚJavaµÄµ¥¼Ì³ÐÌØÐÔ´øÀ´µÄ¾ÖÏÞ¡£ÎÒÃǾ­³£Åöµ½ÕâÑùÒ»ÖÖÇé¿ö£¬¼´µ±ÎÒÃÇÒª½«ÒѾ­¼Ì³ÐÁËijһ¸öÀàµÄ×ÓÀà·ÅÈë¶àÏß³ÌÖУ¬ÓÉÓÚÒ»¸öÀ಻ÄÜͬʱÓÐÁ½¸ö¸¸À࣬ËùÒÔ²»ÄÜÓü̳ÐThreadÀàµÄ·½Ê½£¬ÄÇô£¬Õâ¸öÀà¾ÍÖ»ÄܲÉÓÃʵÏÖRunnable¡£
l         µ±Ï̱߳»¹¹Ôìʱ£¬ÐèÒªµÄ´úÂëºÍÊý¾Ýͨ¹ýÒ»¸ö¶ÔÏó×÷Ϊ¹¹Ô캯Êýʵ²Î´«µÝ½øÈ¥£¬Õâ¸ö¶ÔÏó¾ÍÊÇÒ»¸öʵÏÖÁËRunnable½Ó¿ÚµÄÀàµÄʵÀý¡£
l         ÊÂʵÉÏ£¬¼¸ºõËùÓжàÏß³ÌÓ¦Óö¼¿ÉÒÔÓÃRunnable½Ó¿Ú·½Ê½¡£
ÀýÈ磺ÓÐËĸö´°¿ÚÏúÊÛ100ÕÅ»ð³µÆ±£¬
Class TestThread implements Runnable//ʹÓÃʵÏÖRunnable½Ó¿ÚµÄ·½Ê½£¬ÊµÏÖ´úÂëºÍÊý¾ÝµÄ·ÖÀë
{
       int tickets=100;
       public void run()
{
While(true)
{
If(tickets>0)
System.out.println(Thread.currentThread().getName()+”in salling ticket”+tickets--);
//Ëĸö´°¿ÚͬʱÂô£¬Ï൱ÓÚËĸö½ø³Ì¹²Ïítickets±äÁ¿£»Ëĸö½ø³Ì¹²Í¬Ê¹ÓÃÕâÒ»¶Î´úÂë
}
 
}
}
 
Public class Test{
   &n


Ïà¹ØÎĵµ£º

java »·¾³±äÁ¿µÄÅäÖà ºÍTomcatµÄÅäÖÃ

 javaµÚÒ»²½——JDK»·¾³±äÁ¿ÅäÖÃ
ÏÂÔغõÄJDKÊÇÒ»¸ö¿ÉÖ´Ðа²×°³ÌÐò£¬Ë«»÷°²×°¡£½«°²×°Â·¾¶¸ÄΪ£ºC:\jdk1.6.0£¨µ±È»ÆäËû·¾¶Ò²¿ÉÒÔ£©¡£
JDK°²×°Íê³ÉÖ®ºóÎÒÃÇÀ´ÉèÖû·¾³±äÁ¿£º
ÎҵĵçÄÔµãÓÒ¼ü£¬Ñ¡Ôñ“ÊôÐÔ”£¬Ñ¡Ôñ“¸ß¼¶”±êÇ©£¬½øÈë»·¾³±äÁ¿ÉèÖ㬷ֱðÉèÖÃÈçÏÂÈý¸ö»·¾³±äÁ¿£º
£¨1£©É ......

java´ò°üjar ´øjre

 Ð´¸öMANIFEST.MF
Manifest-Version: 1.0
Created-By: shijishang
Main-Class: test2
×¢ÒâðºÅÖ®ºóÓпոñ£¬×îºóÒª¿ÕÁ½ÐÐ
ÓÃÃüÁîjar cvfm classes.jar META-INF/MANIFEST.MF classes
д¸öCMDÃüÁî
@echo off
java -jar -verbose:class classes.jar >> class.txt
pause
µ¼³öÐèÒª¾«¼òµÄ»ù±¾Àà
ÔÙÓÃÒÔÉÏ´ò ......

Java 7ÒѾ­Íê³ÉµÄÆß´óй¦ÄÜÔ¤ÀÀ

 
Java 7ÒѾ­Íê³ÉµÄÆß´óй¦ÄÜÔ¤ÀÀ  ×ª×Ô51CTO
½ñÄêµÄDevoxx´ó»áÓÖÊÇÒ»´ÎÓйØJava 7½ø³ÌµÄÒ»´Îչʾ´ó»á¡£Ò»Î»DevoxxµÄ²Î»áÕßÔÚ²©¿ÍÖб¨¸æÁËJava 7ÏÖÔÚÒѾ­Íê³ÉµÄ7´óй¦ÄÜ¡£Java 7Ô¤¼Æ½«ÔÚ2010Äê9ÔÂÕýʽµ½À´¡£
JigsawÏîÄ¿¼ò½é£ºJava 7µÄÐÂÄ£¿éϵͳ
̽ÃØJava 7ÐÂÔöÀ¬»ø»ØÊÕÆ÷G1ÌØÐÔ
̽ÃØJava 7£ºJVM¶¯Ì¬ÓïÑÔÖ ......

Java SE 6 Beta

 
Sun·¢²¼ÁËJava SE 6 Beta
£¨ÒÔϼò³Æ6£©£¬²éÁ˲鹦ÄܸĽø
£¬Ã»Óз¢ÏÖʲô¼¤¶¯ÈËÐĵı仯¡£ÌôÁ˼¸ÌõÉÔ΢¸ÐÐËȤһµãµÄÆÀ¼Ûһϡ£
jconsole is more user-friendly
6µÄн¨Á¬½ÓµÄ´°¿ÚÓзdz£´óµÄ¸Ä±ä¡£ÔÚLocal Process´°¿ÚÁгöÁËËùÓб¾µØjava½ø³Ì£¨°üÀ¨jconsole±¾Éí£©£¬²»ÄÜͨ¹ýJconsole½øÐйÜÀíµÄ½ø³Ì´¦ÓÚdisable× ......

Java Web¿ª·¢¹¹Ïë

 1£®±³¾°¡¢ÐÎÊÆ
Äܹ»½øÐÐWeb¿ª·¢µÄ±à³ÌÓïÑԺͼ¼ÊõºÜ¶à
(1) ¶¯Ì¬½âÊÍÓïÑÔ
PHP; Perl; Python (Zope, Plone); Ruby (Ruby on Rails);
(2) ±àÒëÓïÑÔ
Java; .net
Java Web¿ª·¢Ô¶·ÇÒ»Ö¦¶ÀÐ㣺
³ýÁËÊܵ½À´×Ô.net Õâ¸öÖØÁ¿¼¶¶ÔÊÖµÄ×î´óÌôÕ½Ö®Í⣬¸üÊܵ½Zope, Ruby on Rail µÈÐÂʽÇáÆï±øµÄ³å»÷£¨µ±È»£¬Ò²¼ÌÐøÊܵ½ÀÏʽÇá ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ