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

´Ójava³ÌÐòÖе÷ÓÃÆäËü³ÌÐò

RMI (Remote Method Invocation£¬Ô¶³Ì·½·¨µ÷ÓÃ)ÈçºÎÓÃÓÚ³ÌÐò¼äͨѶ£¬ÁíÒ»¸öÓÃÓÚͨѶµÄ¼¼ÊõÊÇRuntime.exec() ·½·¨¡£Äã¿ÉÒÔÓÃÕâ¸ö·½·¨´ÓÒ»¸öÔËÐа¢java³ÌÐòÖе÷ÓÃÁíÒ»¸ö³ÌÐò¡£Runtime.exec Ò²ÔÊÐíÄãÖ´ÐкͳÌÐòÏà¹ØµÄ²Ù×÷£¬ÀýÈç¿ØÖƳÌÐòµÄ±ê×¼ÊäÈëÊä³ö£¬µÈ´ý³ÌÐòµÄ½áÊø²¢µÃµ½ËüµÄÍ˳ö״̬¡£ÏÂÃæÊÇÒ»¸ö¼òµ¥µÄC³ÌÐò£¬ÓÃÀ´ËµÃ÷ÕâЩÌØÐÔ£º
    #include <stdio.h>
    int main() {
        printf("testing\n");
        return 0;
    }
Õâ¸ö³ÌÐòд×Ö·û´®"testing"µ½±ê×¼Êä³ö£¬È»ºóÓÃÍ˳ö״̬0ÖÕÖ¹³ÌÐò¡£
ΪÁËÔÚjava³ÌÐòÖÐÖ´ÐÐÕâ¸ö¼òµ¥µÄ³ÌÐò£¬ÏȱàÒëÕâ¸öc³ÌÐò£º
    $ cc test.c -o test
£¨ÒëÕß×¢£º¶ÔÓÚlinuxÓû§£¬¿ÉÒÔÓÃgcc test.c ?o test,¶ÔÓ¦windowsÓû§¿ÉÒÔÓÃÏàÓ¦µÄcÓïÑÔ±àÒë³ÌÐò±àÒë³É¿ÉÖ´ÐгÌÐòtest.exe£©    
(ÄãµÄ C ±àÒëÆ÷¿ÉÄÜÒªÇó²»Í¬µÄ²ÎÊý)È»ºóʹÓÃÏÂÃæµÄ´úÂëµ÷ÓÃÄǸö³ÌÐò£º
    import java.io.*;
    import java.util.ArrayList;
    
    public class ExecDemo {
        static public String[] runCommand(String cmd)
            throws IOException {
    
            // set up list to capture command output lines
    
            ArrayList list = new ArrayList();
    
            // start command running
   
Process proc = Runtime.getRuntime().exec(cmd);
/**ÒëÕß×


Ïà¹ØÎĵµ£º

Java json lib

Java json lib
¸ù¾Ýhttp://www.javaeye.com/topic/561368̸µ½µÄÒ»¸öjacksonµÄjsonÐòÁл¯¹¤¾ßÐÔÄܱÈjson-libµÈÒªºÃ
ÎÞÂÛÊÇÔڵͲ¢·¢»¹ÊǸ߲¢·¢µÄÇé¿öÏ£¬Ê±¼äÐÔÄÜÉÏ£¬jacksonʹÓÃÖØÓÃObjectMapper·½Ê½´ó´óÓÅÓÚʹÓÃjson-lib·½Ê½£¬ÉõÓÚjacksonʹÓ÷ÇÖØÓÃObjectMapper·½Ê½Ò²ÂÔÓÅÓÚjson-lib·½Ê½¡£ÁíÍâÒ²¿ÉÒÔ¿´³ö£¬jacksonÔÚÖØÓà ......

JavaÄÚ²¿ÀࣨInner Class£©Ïê½â

¼òµ¥µÄ˵£¬ÄÚ²¿£¨inner£©ÀàÖ¸ÄÇЩÀඨÒå´úÂë±»ÖÃÓÚÆäËüÀඨÒåÖеÄÀࣻ¶ø¶ÔÓÚÒ»°ãµÄ¡¢ÀඨÒå´úÂ벻ǶÌ×ÔÚÆäËüÀඨÒåÖеÄÀ࣬³ÆΪ¶¥²ã£¨top-level£©Àà¡£¶ÔÓÚÒ»¸öÄÚ²¿À࣬°üº¬Æ䶨Òå´úÂëµÄÀà³ÆΪËüµÄÍⲿ£¨outer£©Àà¡£
1          Static member class£¨¾²Ì¬³ÉÔ±Àࣩ
ÀàÉùÃ÷ÖÐ ......

Java¸´Ï°±Ê¼Ç µÚ9Ìì


Hibernate
    
Hibernate
ÊÇÒ»¸öÓÅÐãµÄ³Ö¾Ã»¯¿ò¼Ü
    
˲ʱ״̬£¬³Ö¾Ã״̬
    
ORM
£º¶ÔÏó¹ØϵӳÉ䣬Íê³É¶ÔÏóÊý¾Ýµ½¹ØϵÊý¾ÝµÄÓ³Éä»úÖÆ
    
ʹÓÃ
Hibernate
µÄÈýÏî×¼±¸¹¤×÷ÊÇ£º
1¡¢ 
Ìí¼Ó
hibernate
¿â
......

É÷ÓÃJava×°ÏäÓë²ðÏä

ת×Ôhttp://xyiyy.javaeye.com/blog/358401
J2SE5.0ºóÌṩÁË×Ô¶¯×°ÏäÓë²ðÏäµÄ¹¦ÄÜ£¬´Ë¹¦ÄÜÊÂʵÉÏÊDZàÒëÆ÷À´°ïÄúµÄ棬±àÒëÆ÷ÔÚ±àÒëʱÆÚÒÀÄúËù±àдµÄ·½·¨£¬¾ö¶¨ÊÇ·ñ½øÐÐ×°Ïä»ò²ðÏ䶯×÷¡£ÀýÈ磺
                     ......

javaËÄÉáÎåÈëBigDecimal

javaËÄÉáÎåÈë
package Test;
import java.math.BigDecimal; //ÒýÈëÕâ¸ö°ü
public class Test {
  public static void main(String[] args) {
   double i = 3.856;
   // ÉáµôСÊýÈ¡Õû
   System.out.println("ÉáµôСÊýÈ¡Õû:Math.floor(3.856)=" + (int) Math.floor(i));
......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ