Java±àÒëÆ÷¡¢JVM¡¢½âÊÍÆ÷
Java
ÐéÄâ»ú(JVM)ÊÇ¿ÉÔËÐÐJava
´úÂëµÄ¼ÙÏë¼ÆËã»ú¡£Ö»Òª¸ù¾ÝJVM¹æ¸ñÃèÊö½«½âÊÍÆ÷ÒÆÖ²µ½Ìض¨µÄ¼ÆËã»úÉÏ£¬¾ÍÄܱ£Ö¤¾¹ý±àÒëµÄÈκÎJava´úÂëÄܹ»ÔÚ¸ÃϵͳÉÏÔËÐС£±¾ÎÄÊ×ÏȼòÒª½éÉÜ´ÓJavaÎļþµÄ±àÒëµ½×îÖÕÖ´ÐеĹý³Ì£¬Ëæºó¶ÔJVM¹æ¸ñÃèÊö×÷һ˵Ã÷¡£
¡¡¡¡
¡¡¡¡Ò».JavaÔ´ÎļþµÄ±àÒë¡¢ÏÂÔØ
¡¢½âÊͺÍÖ´ÐÐ
¡¡¡¡JavaÓ¦ÓóÌÐòµÄ¿ª·¢ÖÜÆÚ°üÀ¨±àÒë¡¢ÏÂÔØ
¡¢½âÊͺÍÖ´Ðм¸¸ö²¿·Ö¡£Java±àÒë³ÌÐò½«JavaÔ´³ÌÐò·ÒëΪJVM¿ÉÖ´ÐдúÂë?×Ö½ÚÂë¡£ÕâÒ»±àÒë¹ý³ÌͬC/C++
µÄ
±àÒëÓÐЩ²»Í¬¡£µ±C±àÒëÆ÷±àÒëÉú³ÉÒ»¸ö¶ÔÏóµÄ´úÂëʱ£¬¸Ã´úÂëÊÇΪÔÚijһÌض¨Ó²¼þƽ̨ÔËÐжø²úÉúµÄ¡£Òò´Ë£¬ÔÚ±àÒë¹ý³ÌÖУ¬±àÒë³ÌÐòͨ¹ý²é±í½«ËùÓжԷûºÅµÄÒý
ÓÃת»»ÎªÌض¨µÄÄÚ´æÆ«ÒÆÁ¿£¬ÒÔ±£Ö¤³ÌÐòÔËÐС£Java±àÒëÆ÷È´²»½«¶Ô±äÁ¿ºÍ·½·¨µÄÒýÓñàÒëΪÊýÖµÒýÓã¬Ò²²»È·¶¨³ÌÐòÖ´Ðйý³ÌÖеÄÄÚ´æ²¼¾Ö£¬¶øÊǽ«ÕâЩ·ûºÅ
ÒýÓÃÐÅÏ¢±£ÁôÔÚ×Ö½ÚÂëÖУ¬ÓɽâÊÍÆ÷ÔÚÔËÐйý³ÌÖд´Á¢ÄÚ´æ²¼¾Ö£¬È»ºóÔÙͨ¹ý²é±íÀ´È·¶¨Ò»¸ö·½·¨ËùÔڵĵØÖ·¡£ÕâÑù¾ÍÓÐЧµÄ±£Ö¤ÁËJavaµÄ¿ÉÒÆÖ²ÐԺͰ²È«
ÐÔ¡£
¡¡¡¡
¡¡
¡¡ÔËÐÐJVM×Ö½ÚÂëµÄ¹¤×÷ÊÇÓɽâÊÍÆ÷À´Íê³ÉµÄ¡£½âÊÍÖ´Ðйý³Ì·ÖÈý²¿½øÐУº´úÂëµÄ×°Èë¡¢´úÂëµÄУÑéºÍ´úÂëµÄÖ´ÐС£×°Èë´úÂëµÄ¹¤×÷ÓÉ"Àà×°ÔØÆ÷"£¨class
loader£©Íê³É¡£Àà×°ÔØÆ÷¸ºÔð×°ÈëÔËÐÐÒ»¸ö³ÌÐòÐèÒªµÄËùÓдúÂ룬ÕâÒ²°üÀ¨³ÌÐò´úÂëÖеÄÀàËù¼Ì³ÐµÄÀàºÍ±»Æäµ÷ÓõÄÀà¡£µ±Àà×°ÔØÆ÷×°ÈëÒ»¸öÀàʱ£¬¸ÃÀà±»·Å
ÔÚ×Ô¼ºµÄÃû×Ö¿Õ¼äÖС£³ýÁËͨ¹ý·ûºÅÒýÓÃ×Ô¼ºÃû×Ö¿Õ¼äÒÔÍâµÄÀ࣬ÀàÖ®¼äûÓÐÆäËû°ì·¨¿ÉÒÔÓ°ÏìÆäËûÀà¡£ÔÚ±¾Ì¨¼ÆËã»úÉϵÄËùÓÐÀ඼ÔÚͬһµØÖ·¿Õ¼äÄÚ£¬¶øËùÓдÓÍâ
²¿Òý½øµÄÀ࣬¶¼ÓÐÒ»¸ö×Ô¼º¶ÀÁ¢µÄÃû×ֿռ䡣ÕâʹµÃ±¾µØÀàͨ¹ý¹²ÏíÏàͬµÄÃû×Ö¿Õ¼ä»ñµÃ½Ï¸ßµÄÔËÐÐЧÂÊ£¬Í¬Ê±ÓÖ±£Ö¤ËüÃÇÓë´ÓÍⲿÒý½øµÄÀ಻»áÏ໥ӰÏì¡£µ±×°Èë
ÁËÔËÐгÌÐòÐèÒªµÄËùÓÐÀàºó£¬½âÊÍÆ÷±ã¿ÉÈ·¶¨Õû¸ö¿ÉÖ´ÐгÌÐòµÄÄÚ´æ²¼¾Ö¡£½âÊÍÆ÷Ϊ·ûºÅÒýÓÃͬÌض¨µÄµØÖ·¿Õ¼ä½¨Á¢¶ÔÓ¦¹Øϵ¼°²éѯ±í¡£Í¨¹ýÔÚÕâÒ»½×¶ÎÈ·¶¨´úÂëµÄ
ÄÚ´æ²¼¾Ö£¬JavaºÜºÃµØ½â¾öÁËÓɳ¬Àà¸Ä±ä¶øʹ×ÓÀà±ÀÀ£µÄÎÊÌ⣬ͬʱҲ·ÀÖ¹ÁË´úÂë¶ÔµØÖ·µÄ·Ç·¨·ÃÎÊ¡£
¡¡¡¡
¡¡¡¡Ëæºó£¬±»×°ÈëµÄ´úÂëÓÉ×Ö½ÚÂëУÑéÆ÷½øÐмì²é¡£Ð£ÑéÆ÷¿É·¢ÏÖ²Ù×÷ÊýÕ»Òç³ö£¬·Ç·¨Êý¾ÝÀàÐÍת»¯µÈ¶àÖÖ´íÎó¡£Í¨¹ýУÑéºó£¬´úÂë±ã¿ªÊ¼Ö´ÐÐÁË¡£
¡¡¡¡
¡¡¡¡Java×Ö½ÚÂëµÄÖ´ÐÐÓÐÁ½ÖÖ·½Ê½£º
¡¡¡¡1.¼´Ê±±àÒ뷽ʽ£º½âÊÍÆ÷ÏȽ«×Ö½ÚÂë±àÒë³É»úÆ÷Â룬ȻºóÔÙÖ´ÐиûúÆ÷Âë¡£
¡¡¡¡2.½âÊÍÖ´Ðз½Ê½£º½âÊÍÆ÷ͨ¹ýÿ´Î½âÊͲ¢Ö´ÐÐһС¶Î´úÂëÀ´Íê³ÉJava×Ö½ÚÂë³Ì Ð
Ïà¹ØÎĵµ£º
Why NIO ?
http://onjava.com/pub/a/onjava/2002/09/04/nio.html?page=1
Java developers might ask: why introducing a new technology to handle sockets? What's wrong with the Java 1.3.x sockets? Suppose you would like to implement a server accepting diverse client connections. Suppose, as well, that you ......
JAVAÖеÄÖ÷º¯ÊýÊÇÎÒÃÇÔÙÊìϤ²»¹ýµÄÁË£¬ÏàÐÅÿ¸öѧϰ¹ýJAVAÓïÑÔµÄÈ˶¼Äܹ»ÊìÁ·µØд³öÕâ¸ö³ÌÐòµÄÈë¿Úº¯Êý£¬µ«¶ÔÓÚÖ÷º¯ÊýΪʲôÕâôд£¬ÆäÖеÄÿ¸ö¹Ø¼ü×Ö·Ö±ðÊÇʲôÒâ˼£¬¿ÉÄܾͲ»ÊÇËùÓÐÈ˶¼ÄÜÇáËɵشð³öÀ´µÄÁË¡£ÎÒÒ²ÊÇÔÚѧϰÖÐÅöµ½ÁËÕâ¸öÎÊÌ⣬ͨ¹ýÔÚÍøÉÏËÑË÷×ÊÁÏ£¬²¢¼ÓÉÏ×Ô¼ºµÄʵ¼ùÖÕÓÚÓÐÁËÒ»µãÐĵ㬲»¸Ò±£Áô£¬Ð´³öÀ´Óë´ó¼Ò ......
package com.word.tools.pool;
import java.util.Vector;
import com.word.po.ObjectPool_Param;
import com.word.po.TyjkXmlPO;
public class TyjkXmlPool
{
/**¶ÔÏó³Ø²ÎÊý*/
private ObjectPool_Param ob_param;
/**´æ·Å¶ÔÏóµÄVector*/
......
ËäÈ»²»¾õµÃÔÚ±à³ÌʱÕýÈ·ÅжÏjavaÀà³õʼ»¯¹¤×÷ÏȺó˳Ðò»áÊÇÒ»¸öÌôÕ½£¬ÇÒ¶ÔÓÚÀà³õʼ»¯µÄÈÏʶ»¹Ö»Í£ÁôÔÚÓïÑÔÌØÐÔ»úÖƵIJãÃæ(»òÐí»áÊÇÒ»ÖÖʵÏÖ¼¼ÇÉÁìÓòµÄÒéÌâ)£¬µ«¶ÔÓÚ¹ØÓÚ³õʼ»¯ÕâÀàÁãÉ¢¶øÓÖϸСµÄ֪ʶµã£¬×ܽỹÊÇÓмÛÖµµÄ ......
1.InputStreamºÍOutputStreamÊÇÓÃÓÚ¶Á»òдµ¥¸ö×Ö½Ú»òÕß×Ö½ÚÊý×飬ÎÒÃǺÜÉÙÓõ½ËüÃǵķ½·¨£¬ËüÃÇÖ®ËùÒÔ´æÔÚÊÇÒòΪ±ðµÄÀà¿ÉÒÔʹÓÃËüÃÇ£¬ÒÔ±ãÌṩ¸üÓÐÓõĽӿڡ£Òò´Ë£¬ÎÒÃǺÜÉÙʹÓõ¥Ò»µÄÀàÀ´´´½¨Á÷¶ÔÏ󣬶øÊÇͨ¹ýµþºÏ¶à¸ö¶ÔÏóÀ´ÌṩËùÆÚÍûµÄ¹¦ÄÜ¡£
2.FilterInputStreamºÍFilterOutputStreamÊÇÓÃÀ´ÌṩװÊÎÆ÷Àà½Ó¿ÚÒÔ¿ØÖÆÌض¨ ......