java ¹ØÓÚ½ø³Ì¹ÜÀí
java.lang
Àà Process
java.lang.Object
java.lang.Process
--------------------------------------------------------------------------------
public abstract class Processextends ObjectProcessBuilder.start() ºÍ Runtime.exec ·½·¨´´½¨Ò»¸ö±¾»ú½ø³Ì£¬²¢·µ»Ø Process ×ÓÀàµÄÒ»¸öʵÀý£¬¸ÃʵÀý¿ÉÓÃÀ´¿ØÖƽø³Ì²¢»ñÈ¡Ïà¹ØÐÅÏ¢¡£Process ÀàÌṩÁËÖ´Ðдӽø³ÌÊäÈë¡¢Ö´ÐÐÊä³öµ½½ø³Ì¡¢µÈ´ý½ø³ÌÍê³É¡¢¼ì²é½ø³ÌµÄÍ˳ö״̬ÒÔ¼°Ïú»Ù£¨É±µô£©½ø³ÌµÄ·½·¨¡£
´´½¨½ø³ÌµÄ·½·¨¿ÉÄÜÎÞ·¨Õë¶ÔijЩ±¾»úƽ̨ÉϵÄÌض¨½ø³ÌºÜºÃµØ¹¤×÷£¬±ÈÈ磬±¾»ú´°¿Ú½ø³Ì£¬ÊØ»¤½ø³Ì£¬Microsoft Windows É쵀 Win16/DOS ½ø³Ì£¬»òÕß shell ½Å±¾¡£´´½¨µÄ×Ó½ø³ÌûÓÐ×Ô¼ºµÄÖն˻ò¿ØÖÆ̨¡£ËüµÄËùÓбê×¼ io£¨¼´ stdin£¬stdout£¬stderr£©²Ù×÷¶¼½«Í¨¹ýÈý¸öÁ÷ (getOutputStream()£¬getInputStream()£¬getErrorStream()) Öض¨Ïòµ½¸¸½ø³Ì¡£¸¸½ø³ÌʹÓÃÕâЩÁ÷À´Ìṩµ½×Ó½ø³ÌµÄÊäÈëºÍ»ñµÃ´Ó×Ó½ø³ÌµÄÊä³ö¡£ÒòΪÓÐЩ±¾»úƽ̨½öÕë¶Ô±ê×¼ÊäÈëºÍÊä³öÁ÷ÌṩÓÐÏ޵Ļº³åÇø´óС£¬Èç¹û¶Áд×Ó½ø³ÌµÄÊä³öÁ÷»òÊäÈëÁ÷ѸËÙ³öÏÖʧ°Ü£¬Ôò¿ÉÄܵ¼ÖÂ×Ó½ø³Ì×èÈû£¬ÉõÖÁ²úÉúËÀËø¡£
µ±Ã»ÓÐ Process ¶ÔÏóµÄ¸ü¶àÒýÓÃʱ£¬²»ÊÇɾµô×Ó½ø³Ì£¬¶øÊǼÌÐøÒì²½Ö´ÐÐ×Ó½ø³Ì¡£
¶ÔÓÚ´øÓÐ Process ¶ÔÏóµÄ Java ½ø³Ì£¬Ã»ÓбØÒªÒì²½»ò²¢·¢Ö´ÐÐÓÉ Process ¶ÔÏó±íʾµÄ½ø³Ì¡£
´ÓÒÔÏ°汾¿ªÊ¼£º
JDK1.0
ÁíÇë²Î¼û£º
ProcessBuilder, Runtime.exec(String[], String[], File)
--------------------------------------------------------------------------------
¹¹Ôì·½·¨ÕªÒª
Process()
·½·¨ÕªÒª
abstract void destroy()
ɱµô×Ó½ø³Ì¡£
abstract int exitValue()
·µ»Ø×Ó½ø³ÌµÄ³ö¿ÚÖµ¡£
abstract InputStream getErrorStream()
»ñµÃ×Ó½ø³ÌµÄ´íÎóÁ÷¡£
abstract InputStream getInputStream()
»ñµÃ×Ó½ø³ÌµÄÊäÈëÁ÷¡£
abstract OutputStream getOutputStream()
»ñµÃ×Ó½ø³ÌµÄÊä³öÁ÷¡£
abstrac
Ïà¹ØÎĵµ£º
Java NIO APIÏê½â
ÔÚJDK
1.4ÒÔÇ°£¬JavaµÄIO²Ù×÷¼¯ÖÐÔÚjava.ioÕâ¸ö°üÖУ¬ÊÇ»ùÓÚÁ÷µÄ×èÈû£¨blocking£©API¡£¶ÔÓÚ´ó¶àÊýÓ¦ÓÃÀ´Ëµ£¬ÕâÑùµÄAPIʹÓúܷ½
±ã£¬È»¶ø£¬Ò»Ð©¶ÔÐÔÄÜÒªÇó½Ï¸ßµÄÓ¦Óã¬ÓÈÆäÊÇ·þÎñ¶ËÓ¦Óã¬ÍùÍùÐèÒªÒ»¸ö¸üΪÓÐЧµÄ·½Ê½À´´¦ÀíIO¡£´ÓJDK 1.4Æð£¬NIO
API×÷Ϊһ¸ö»ùÓÚ»º³åÇø£¬²¢ÄÜÌṩ·Ç×èÈû(non-blo ......
ÀàµÄ³õʼ»¯ºÍ¶ÔÏó³õʼ»¯ÊÇ JVM ¹ÜÀíµÄÀàÐÍÉúÃüÖÜÆÚÖзdz£ÖØÒªµÄÁ½¸ö»·½Ú£¬Google ÁËÒ»±éÍøÂ磬ÓйØÀà×°ÔØ»úÖƵÄÎÄÕµ¹ÊDz»ÉÙ£¬È»¶øÀà³õʼ»¯ºÍ¶ÔÏó³õʼ»¯µÄÎÄÕ²¢²»¶à£¬ÌرðÊÇ´Ó×Ö½ÚÂëºÍ JVM ²ã´ÎÀ´·ÖÎöµÄÎÄÕ¸üÊÇÏÊÓÐËù¼û¡£
±¾ÎÄÖ÷Òª¶ÔÀàºÍ¶ÔÏó³õʼ»¯È«¹ý³Ì½øÐзÖÎö£¬Í¨¹ýÒ»¸öʵ¼ÊÎÊÌâÒýÈ룬½«Ô´´úÂëת»»³É JVM ×Ö½ÚÂëºó£¬ ......
LSParserFilter---ÔØÈëÓë±£´æ
Ó¦ÓÃorg.w3c.dom ʵÏÖXMLµÄÔØÈëÓë±£´æʵÀý
/**
* ʵÏÖDOM3µÄLS(Load & Save)¹¦ÄÜ
*
* @author S.Well
* @see org.w3c.dom.DOMErrorHandler
* @see org.w3c.dom.ls.LSParserFilter
*/
public class XML_LS implements DOMErrorHandler, LSParserFilter {
private static ......
JAVA¶ÁXML£ºsax,dom,jdom,dom4jµÄ±È½ÏÒÔ¼°Ñ¡Ôñ(ת)
ÔÎÄ£ºwww.hicourt.gov.cn/homepage/show9_content.asp
SAX£º ......
JAVA IOÁ÷µÄÓ¦ÓÃ
IOÁ÷µÄµäÐÍÓ¦ÓÃ
¾¡¹Ü¿âÄÚ´æÔÚ´óÁ¿IOÁ÷À࣬¿Éͨ¹ý¶àÖÖ²»Í¬µÄ·½Ê½×éºÏµ½Ò»Æ𣬵«Êµ¼ÊÉÏÖ»Óм¸ÖÖ·½Ê½²Å»á¾³£Óõ½¡£È»¶ø£¬±ØÐëСÐÄÔÚÒâ²ÅÄܵõ½ÕýÈ·µÄ×éºÏ¡£ÏÂÃæÕâ¸öÏ൱³¤µÄÀý×ÓչʾÁ˵äÐÍIOÅäÖõĴ´½¨ÓëʹÓ㬿ÉÔÚд×Ô¼ºµÄ´úÂëʱ½«Æä×÷Ϊһ¸ö²Î¿¼Ê¹Óá£×¢Òâÿ¸öÅäÖö¼ÒÔÒ»¸ö×¢ÊÍÐ ......