JavaScriptͦÈë·þÎñÆ÷¶Ë¿ª·¢ÓïÑÔÐòÁÐ
ÔÎÄÁ´½Ó£ºJavaScript: Its Not Just for Browsers Any More
Node.jsÊÇÒ»Ì×ÓÃÀ´±àд¸ßÐÔÄÜÍøÂç·þÎñÆ÷µÄJavaScript¹¤¾ß°ü£¬Ò»ÏµÁеı仯ÓÉ´Ë¿ªÊ¼¡£
Ò²ÐíÄ㻹²»ÖªµÀ£¬JavaScriptÏÖÔÚÒѾ³ÉÁËÒ»Ãſɱàд³öЧÂʼ«¸ßµÄ¡¢¿ÉÓÃÓÚ¿ª·¢²úÆ·¼¶web·þÎñÆ÷µÄ³öÉ«ÓïÑÔ¡£Æð³õÎÒÒ²²»ÏàÐÅ£¬µ«2009 ÄêÆô¶¯µÄÁ½¸öÏîÄ¿ÈÃÕâ³ÉΪ¿ÉÄÜ£ºCommonJSºÍNode¡£
¾¡¹ÜJavaScriptÒѾ³öÏֺܳ¤Ò»¶Îʱ¼äÁË£¬ÔËÓÃÒ²ºÜ¹ã·º£¨¿ÉÒÔ˵ÊÇÕâÒ»ÐÇÇòÉÏ×î³£Óõıà³ÌÓïÑÔ£©£¬µ«ËüÒ»Ö±Ö»ÊǾÖÏÞÔÚä¯ÀÀÆ÷µÄ·¶Î§ÄÚ¡£Óë´Ë ͬʱ£¬Ò»Ð©¿ò¼ÜÊÔͼ½«JavaScriptÒýÈëµ½·þÎñÆ÷¶Ë£¬ÕâЩ¿ò¼ÜÓÐAptana Jaxer£¬£¨²ÉÓÃÁËSpiderMonkeyµÄ JavaScript½âÊÍÆ÷£©ºÍHelma£¨»ùÓÚRhino£©£¬µ«×ÔÉíµÄ²»×ãÓÖÖÆÔ¼×ÅËüÃǵÄÆÕ¼°¡£
¼¼ÊõÉú̬Ȧ
µ±ÎÒÃÇÑ¡ÔñijÖÖ¼¼Êõ±àдӦÓóÌÐòʱ£¬ÎÒÃDz»Ö»ÊÇÑ¡Ôñ±à³ÌÓïÑÔ£¬»¹Í¬Ê±Ñ¡ÔñÁËÆäÏàÓ¦µÄ¿âÎļþ¡£Èç¹ûÒ»ÖÖÓïÑÔÓÐÒ»¸ö»îÔ¾µÄÉçÇøÒÔ¼°´óÁ¿¿ÉÓõĿ⣬ÄÇôÄã ºÜÈÝÒ×Óøü¶ÌµÄʱ¼ä±àд³öÄãµÄÓ¦ÓóÌÐò¡£
ËùÓеÄÏÖ´ú±à³ÌÓïÑÔ¶¼ÓÐÒ»¸ö±ê×¼¿âÒÔ¼°Ò»¸öÓÅÐãµÄµÚÈý·½´úÂë¿â×é³ÉµÄ¼¼ÊõÉú̬Ȧ£¨ecosystem£©¡£PythonÊÇÒ»ÖÖÖÚËùÖÜÖªµÄÒÔ batteries included"ΪÌØÉ«µÄÓïÑÔ£¬¶øÇÒÓÐÒ»¸öÓÅÐãµÄÈí¼þ°üÉú̬ȦÐγɵÄPython Package Index (PyPI)£¬RubyºÍPerlÒ²ÊÇÕâÑùµÄ¡£²»ÐÒµÄÊÇ£¬JavaScriptÈ´²¢·ÇÈç´Ë¡£
Ö±µ½×î½ü£¬Äã²ÅÄÜÔÚûÓÐSpiderMonkey, V8, »ò JavaScriptCoreÕâЩJavaScript½âÊÍÆ÷µÄÇé¿öÏ£¬ÔËÐзþÎñ¶ËµÄJavaScript´úÂë¡£µ«ÊÇûÓпâµÄÖ§³Ö£¬Äã¾ÍÎÞ·¨¶à¿ìºÃÊ¡µØ×ö ³öʲôʵ¼ÊµÄ¶«Î÷À´¡£
²»¹ý£¬ÔÚ2009ÄêJavaScriptÉçÇø¾ÍÒâʶµ½ÐèÒª×÷³öһЩ¸Ä±äÁË¡£Kevin DangoorÔÚËûµÄ²©¿ÍÖÐ˵£¬ËäÈ»JavaScriptÊÇÒ»ÖÖºÜͨÐеÄÓïÑÔ£¬µ«È´Ã»ÓÐÐγɱê×¼µÄ¿âAPI£¬Ò²Ã»ÓжÔÍⲿ¿â½øÐдò °üºÍÖƶ¨Í³Ò»µÄµ÷Ó÷½·¨¡£ÓÉÓÚûÓÐͨÓõÄAPI£¬Ã¿¸ö·þÎñ¶ËµÄJavaScriptÏîÄ¿²»µÃ²»¸÷×ÔΪÕþ£¬Õâ²»ÀûÓÚ¿çÏîÄ¿µÄ¿âºÍ¹¤¾ßÐγÉÒ»¸ö¸üÅÓÔ JavaScriptÉú̬Ȧ¡£
Òò´ËDangoorÆô¶¯ÁËServerJSÏîÄ¿¡£Æä×ÚÖ¼ÊÇÖƶ¨Ò»¸ö´óÐ͵ġ¢¿É¼æÈݵÄJavaScriptÉú̬ȦËùÐèµÄAPI¡£ÍƳöÒ»Öܺó ÄÚ£¬ServerJSС×é¾ÍÓÐÁË224Ãû³ÉÔ±£¬ÓʼþÁбíÀïÒ²ÓÐÁË653ÌõÐÅÏ¢¡£ÏÔÈ»£¬DangoorÒѾÒýÆðÁË¿ª·¢ÈËÔ±µÄ×¢Òâ¡£¸ÃÏîÄ¿ºóÀ´¸ÄÃû CommonJS£¬ÒÔ¸üºÃµØ·´Ó³ÆäÍŽáJavaScriptÉçÇø¡¢Îªä¯ÀÀÆ÷¶ËºÍ·þÎñÆ÷¶ËÖƶ¨Í³Ò»APIµÄÕâһΰ´óÄ¿±ê¡£
ͬʱ£¬Ò²ÊÇÔÚ2009Ä꣬Ryan Dahl»¹Æô¶¯ÁËÒ»¸öÃû½ÐNodeµÄJavaScriptȫпò¼Ü¡£NodeÓÖÃûNode.js»òNodejs£¬ºóÃæÕâÁ½¸öÃû³Æ¸üÒ×ÓÚËÑË÷¡£Node°üº¬ ÁËGoogleµÄV8
Ïà¹ØÎĵµ£º
Èç¹ûÄãÏë¼ÓÎÒΪºÃÓÑ£ºÇëµã»÷ÒÔÏÂÁ´½Óhttp://hi.csdn.net/invite.php?u=8943&c=759c7fc189ea23c1
µÚ1ÕÂ
¾«»ª
JavaScript
µÄÌØÐÔÖÐÓÐÒ»²¿
·ÖÌØÐÔ´øÀ´µÄÂé·³Ô¶Ô¶³¬³öËüÃǵļÛÖµ¡£ÆäÖУ¬Ò»Ð©ÌØÐÔÊÇÒòΪ¹æ·¶ºÜ²»ÍêÉÆ£¬´Ó¶ø¿ÉÄܵ¼Ö¿ÉÒÆÖ²ÐÔµÄÎÊÌ⣻һЩÌØÐԻᵼÖÂÉú³ÉÄÑÒÔÀí½âºÍÐ޸ĵĴúÂ룻һЩÌØ
ÐÔ´ ......
http://blog.csdn.net/mouyong/archive/2009/10/04/4631665.aspx
Èç¹ûÄãÏë¼ÓÔ×÷ÕßΪºÃÓÑ£ºÇëµã»÷ÒÔÏÂÁ´½Óhttp://hi.csdn.net/invite.php?u=8943&c=759c7fc189ea23c1
µÚ2ÕÂ Óï·¨
±¾Õ½éÉÜJavaScriptµÄ¾«»ª²¿·ÖµÄÓï·¨£¬²¢¼òÒªµØ¸ÅÊöÆäÓïÑԽṹ¡£
2.1 & ......
http://blog.csdn.net/mouyong/archive/2010/01/10/5169396.aspx
µÚ5Õ ¼Ì³Ð
ÔÚÄÇЩ»ùÓÚÀàµÄÓïÑÔ£¨±ÈÈçJava£©ÖУ¬¼Ì³Ð£¨inheritance»òextends£©ÌṩÁËÁ½¸öÓÐÓõķþÎñ¡£Ê×ÏÈ£¬ËüÊÇ´úÂëÖØÓõÄÒ»ÖÖÐÎʽ¡£Èç¹ûÒ»¸öеÄÀàÓëÒ»¸öÒÑ´æÔÚµÄÀà´ó²¿·ÖÏàËÆ£¬ÄÇôÄãÖ»Ðë¾ßÌå˵Ã÷Æ䲻ͬµã¼´¿É¡£Àà¼Ì³ÐµÄÁíÒ»¸öºÃ´¦ÊÇËü°üÀ¨Á ......
function Pause(obj, pSecond) {
/*ÀûÓÃwindow.eventListϵͳ¶ÔÏóÀ´´«µÝTestÕâ¸öÈõ¶ÔÏó£¬ÕâÊÇÓÉÓÚÄãµÄº¯ÊýÓпÉÄÜÊÇ´ø²ÎÊýµÄ¡£
ÓÉÃæÏò¶ÔÏóµÄ˼Ï룬´«µÝ²ÎÊý¾¡Á¿²»Òª²ÉÓÃÈ«¾Ö±äÁ¿£¬ÒòΪÄãµÄ¶ÔÏóÓпÉÄÜÓÐ1¸öÒ²ÓпÉÄÜÓÐn¸ö£¬¶ø
ÓÐЩʱºòËù´´½¨¶ÔÏóµÄ¸öÊý²¢²»ÊÇÄãÊÂÏÈ¿ÉÒÔÖªµÀµÄ£¬ÄÇôҪ´´½¨È«¾Ö±äÁ¿µÄ¸öÊý×ÔÈ»ºÜÄÑÅжÏÁË ......