JAVAÖÐÀàµÄ³õʼ»¯Ë³Ðò
¶ÔÓÚ¾²Ì¬±äÁ¿¡¢¾²Ì¬³õʼ»¯¿é¡¢±äÁ¿¡¢³õʼ»¯¿é¡¢¹¹ÔìÆ÷£¬ËüÃǵijõʼ»¯Ë³ÐòÒÔ´ËÊÇ£¨¾²Ì¬±äÁ¿¡¢¾²Ì¬³õʼ»¯¿é£©>£¨±äÁ¿¡¢³õʼ»¯¿é£©>¹¹ÔìÆ÷¡£ÎÒÃÇÒ²¿ÉÒÔͨ¹ýÏÂÃæµÄ²âÊÔ´úÂëÀ´ÑéÖ¤ÕâÒ»µã£º
public class InitialOrderTest {
//¾²Ì¬±äÁ¿
public static String staticField = "¾²Ì¬±äÁ¿";
//±äÁ¿
public String field = "±äÁ¿";
//¾²Ì¬³õʼ»¯¿é
static {
System.out.println(staticField);
System.out.println("¾²Ì¬³õʼ»¯¿é");
}
//³õʼ»¯¿é
{
System.out.println(field);
System.out.println("³õʼ»¯¿é");
}
//¹¹ÔìÆ÷
public InitialOrderTest() {
System.out.println("¹¹ÔìÆ÷");
}
public static void main(String[] args) {
new InitialOrderTest();
}
}
ÔËÐÐÒÔÉÏ´úÂ룬ÎÒÃÇ»áµÃµ½ÈçϵÄÊä³ö½á¹û£º
1 ¾²Ì¬±äÁ¿
2 ¾²Ì¬³õʼ»¯¿é
3 ±äÁ¿
4 ³õʼ»¯¿é
5 ¹¹ÔìÆ÷
ÕâÓëÉÏÎÄÖÐ˵µÄÍêÈ«·ûºÏ¡£ÄÇô¶ÔÓڼ̳ÐÇé¿öÏÂÓÖ»áÔõÑùÄØ£¿ÎÒÃÇÈÔÈ»ÒÔÒ»¶Î²âÊÔ´úÂëÀ´»ñÈ¡×îÖ
Ïà¹ØÎĵµ£º
Javaѧϰ´ÓÈëÃŵ½¾«Í¨
Ò»¡¢ JDK (Java Development Kit)
JDKÊÇÕû¸öJavaµÄºËÐÄ£¬°üÀ¨ÁËJavaÔËÐл·¾³£¨Java Runtime Envirnment£©£¬Ò»¶ÑJava¹¤¾ßºÍJava»ù´¡µÄÀà¿â(rt.jar)¡£²»ÂÛʲôJavaÓ¦Ó÷þÎñÆ÷ʵÖʶ¼ÊÇÄÚÖÃÁËij¸ö°æ±¾µÄJDK¡£Òò´ËÕÆÎÕJDKÊÇѧºÃJavaµÄµÚÒ»²½¡£×îÖ÷Á÷µÄJ ......
1.дһ¸öðÅÝÅÅÐòµÄ³ÌÐò¡£
public class Sort
{
public static void main(String[] args)
{
&n ......
1.ʹÓÃjava.util.PropertiesÀàµÄload()·½·¨
¡¡¡¡
¡¡¡¡Ê¾Àý£º
Java´úÂë
InputStream in = lnew BufferedInputStream(new FileInputStream(name));
¡¡¡¡Properties p = new Properties();
¡¡¡¡p.load(in);
InputStream ......
żÏñ³ç°Ý£¨Ò»£©
ÄãµÄżÏñÊÇË£¿ÔÚ¸ßÖÐʱ´ú£¬ÎÒµÄżÏñÊÇÊãÇéÀËÂþ¡¢¸ß¿º¼¤°ºµÄ¿ÕÖв¹¸ø£¨Air Supply£©ÒÔ¼°¾²Èç´¦×Ó¡¢¶¯ÈçÍÑÍõĿÀò·Ã×Â壨Kylie Minogue£©£»ÏÖÔÚÎÒµÄżÏñÊÇDavid Flanagan¡¢Jonathan Knudsen¡¢Elliotte Rusty Harold¡¢Bruce EckelµÈÈË¡£ÄãÎÊÎÒDavid FlanaganµÈÈ˳ª¹ýʲô¸è£¬à¸£¡ÄãÎó»áÁË£¬ËûÃDz» ......