23 05, 2006
Ŷ£¬ÊÀ½ç±
×î½ü¾¹ýÒ»¶Îʱ¼äµÄÕÛÌÚ£¬Îȶ¨ÁËһЩ¡£
blog°áµ½ÁËhttp://liubin.nanshapo.com
»¹ÓÐÒ»¸öhttp://ruby.nanshapo.com
27 06, 2005
[RubyÔ´´úÂëÍêÈ«½â˵]¶ÁÊé±Ê¼Ç-µ¼Èë
rubyµÄһЩԴÎļþµÄÓÃ;£º
rubyÓïÑÔºËÐÄ£º
class.c classÏà¹ØAPI
error.c ´íÎóÏà¹ØAPI
eval.c eval Ïà¹Ø
gc.c À¬»øÊÕ¼¯
object.c ¶ÔÏóϵͳ
parse.y ½âÎö
variable.c ³£Á¿£¬È«¾Ö±äÁ¿£¬Àà±äÁ¿¡£
ruby.h rubyµÄÖ÷ÒªºêºÍÔÐÍ
intern.h rubyµÄC APIµÄÔÐÍ¡£internÊǤÏinternalµÄÂÔд
27 06, 2005
[RubyÔ´´úÂëÍêÈ«½â˵]¶ÁÊé±Ê¼Ç-Ðò
Õâ±¾Êé×÷ÕßÊÇÇàľ·åÀÉ£¬´ó¸ÅÔÚ2002Äê³ö°æ£¬»ùÓÚruby1.7°æ±¾£¨ÏÖÔÚÊÇ1.8£©£¬04ÄêÈ«Ê鹫¿ª£¬ËùÒÔÎÒÃDzÅÓÐÐҵõ½µç×Ӱ棬ÆäµØÖ·Îª£ºhttp://i.loveruby.net/ja/rhg/£¬Î¨Ò»µÄÒź¶ÊÇÈ«ÈÕÓï¡£
²é¿´È«ÎÄ22 06, 2005
rubyÀ©Õ¹cÎļþÃû»¹²»ÄÜÓÃcpp
Ò»¸öºÜ¼òµ¥µÄÎļþ£¬¾ÍÊÇprogramming ruby ÉϵÄÀý×Ó£¨http://www.ruby-cn.org/book/ProgrammingRuby/ext_ruby.html£©£¬Èç¹ûÀ©Õ¹ÃûÊÇcpp£¬Ôò³öÏÖÕâÑùµÄ´íÎó£º
error C2664: 'rb_define_method' : cannot convert parameter 3 from
'unsigned long (unsigned long)' to 'unsigned long (__cdecl *)(...)'
None of the functions with this name in scope match the target type
ÐèÒª¸Ä³É.cµÄÎļþ²ÅÐС£
Èç¹û·ÇÒªÓÃcpp£¬¿ÉÒÔÐÞ¸ÄÈçÏ£º
rb_define_method(cTest, "initialize", RUBY_METHOD_FUNC(t_init), 0);
rb_define_method(cTest, "add", RUBY_METHOD_FUNC(t_add), 1);
30 12, 2004
EzTerm£ºÔÚ¿ØÖÆÌ¨ÉÏ¿ØÖÆÑÕÉ«ºÍ¸ñʽ
require "ezterm"
include EzTerm
print fg_blue, "Hello, ", underline("World"), "!!n", reset_color
´òÓ¡³öÀ´µÄ×Ö·ûΪÀ¶É«£¬ÇÒWorldÓÐÏ»®Ïß¡£
²»¹ýÖ»¶ÔlinuxÓÐЧ¡£
²é¿´È«ÎÄ
24 12, 2004
RubyµÄ±£Áô×Ö
ÏÂÁдÊÓï¾ÍÊÇRubyµÄ±£Áô×Ö¡£
BEGIN class ensure nil self when
END def false not super while
alias defined? for or then yield
and do if redo true
begin else in rescue undef
break elsif module retry unless
case end next return until
19 12, 2004
RubyGems¼ò½é
µ±Ç°×îа汾Ϊ0.8.3
ÏÂÔØµØÖ·£ºhttp://rubyforge.org/frs/?group_id=126
Ö÷Ò³£ºhttp://rubygems.rubyforge.org/wiki/wiki.pl
×îеÄRuby°æ±¾ÒѾ°üº¬RubyGemsÁË¡£
²é¿´È«ÎÄ
17 12, 2004
RubyдµÄ6ÐеÄP2P³ÌÐò
http://developers.slashdot.org/article.pl?sid=04/12/15/1953227
Ò»¸öÈËÓÃ15ÐÐдÁËÒ»¸öp2pµÄPython³ÌÐò£¬È»ºóÓÐÈËÓÃPerlдÁËÒ»¸ö9Ðеġ£
ÕâÀïÓÐÒ»¸ö6ÐеÄRuby°æ±¾£º(×÷Õß:"Florian Gross" <flgr@ccan.de>)
²é¿´È«ÎÄ
16 12, 2004
Ruby½×³Ë¼ÆË㻹Ëã±È½ÏÈõ
if a==1
1
else
a*test(a-1)
end
end
puts test(5000)
²é¿´È«ÎÄ
6 12, 2004
Ruby·Ö²¼Ê½¶ÔÏó
6 12, 2004
ÔÚRubyÖÐÀûÓÃSMTPºÍPOP3ÊÕ·¢Óʼþ
6 12, 2004
RubyºÍSOAP±à³Ì
¼òµ¥¶ÔÏó·ÃÎÊÐÒé(SOAP)ºÜ¿ìµÄ³ÉΪÁËÔ¶³Ì¹ý³Ìµ÷Óã¨RPC£©µÄ±ê×¼ÐÒé¡£
£¨¸ü¶à¹ØÓÚSOAPµÄÐÅÏ¢¿ÉÒÔ·Ö±ð²Î¿´
http://www.linuxmagazine.com/2001-10/soap_04.html
ºÍ http://www.linuxmagazine.com/2002-08/webs_01.html)
4 12, 2004
Ò»¸öÓÐÒâ˼µÄRuby½Å±¾
4 12, 2004
Where Ruby Really Sparkles 6
Continuing the previous example, the following code reads three entries from the tuplespace. Note the last statement, which illustrates using a regular expression in the pattern match.
²é¿´È«ÎÄ4 12, 2004
Where Ruby Really Sparkles 3
With SOAP4R, we specify the first two when creating the SOAP driver, the third when we bind a method to that driver, and the parameters when we call the method.
²é¿´È«ÎÄ4 12, 2004
Where Ruby Really Sparkles 4
4 12, 2004
Where Ruby Really Sparkles 5
Distributed Objects
Let's finish with a brief diversion into distributed Ruby. Now that networking is pervasive, it seems natural to want to start flinging objects around the world. Unfortunately, protocols such as CORBA and RMI take a good deal of effort to use: they require special coding, exception handling, and interface definitions before you can send your first bit over the wire.
²é¿´È«ÎÄ4 12, 2004
Where Ruby Really Sparkles 2
POP In and Read Mail
It's equally easy to receive email from POP mailboxes using Ruby. Let's say you want to run a quick survey on programming languages. Participants vote for their their favorite language by sending an email with the subject line, I like xxxx to a given email address, replacing xxxx with a name. The Ruby script in Listing Three could be used to fetch these emails from your POP server and calculate results. This example saves the counts for each language in flat files, one file per language.
²é¿´È«ÎÄ4 12, 2004
Where Ruby Really Sparkles 1
ÔÎÄ£ºhttp://www.linux-mag.com/2002-09/ruby_01.html
If you're looking for a simple, elegant way to script access to the Internet, you should probably take a look at Ruby (for an introduction to Ruby see "A Ruby Refresher"). Ruby is concise (like Python), fully object-oriented (like SmallTalk), and powerful (like Perl). In addition, Ruby is a remarkably capable language for building Internet applications. Ruby's libraries and built-in networking support make networked applications (such as email clients, SOAP servers, and distributed processing) easy to write and easy to maintain and extend. Yeah, take a look at Ruby and learn what its many fans already know: Ruby really connects.
²é¿´È«ÎÄ4 12, 2004
37¸öÎÒ°®RubyµÄÀíÓÉ
ÎÒ²»´òËãÀË·Ñʱ¼äÀ´Ì¸ÂÛRubyµÄÀúÊ·£¬Èç¹ûÄãûÓÐÌý˵¹ýËü£¬Äã¿ÉÒÔÈ¥ËüµÄÖ÷Ò³¿´¿´www.ruby-lang.org£¬»òÕßÈ¥ËüµÄÐÂÎÅ×écomp.lang.ruby¡£Èç¹ûÄãÖªµÀRuby£¬ÎÒ½«½²ÊöÎÒΪʲô»áϲ°®Ëü¡££¨ÄãÒ²¿ÉÄÜÈ¥ÎÒµÄRubyÖ÷Ò³»òÕ߸öÈËÖ÷Ò³¿´¿´£©
²é¿´È«ÎÄ1 12, 2004
Arrow¼ò½é
ArrowÊÇÒ»¸öÄÜÈÃÄãÇáËÉʹÓÃmod_ruby¿ª·¢»ùÓÚapacheµÄwebÓ¦ÓóÌÐòµÄ¿ò¼Ü¡£
Ö÷Ò³£ºhttp://www.rubycrafters.com/projects/Arrow/
²é¿´È«ÎÄ29 11, 2004
ʹÓà Eclipse ºÍ RDT ¿ª·¢RubyÓ¦ÓóÌÐò
ʹÓÃÓà Eclipse ºÍ RDT ¿ª·¢RubyÓ¦ÓóÌÐò
RDT(Ruby Development Tools)£¬Ò»×éEclipse²å¼þ£¬Ê¹µÃEclipseÄÜÖ§³ÖRuby¿ª·¢¡£ ¶øEclipseÊÇÒ»¸ö¹¦ÄÜÇ¿´óµÄ¿çƽ̨¼¯³É¿ª·¢»·¾³£¬Ö§³Ö¶Ôjava£¬jsp£¬phpµÈµØ¿ª·¢¡£
25 11, 2004
RubyÖи÷GUI toolkitµÄ±È½Ï (3)
25 11, 2004
RubyÖи÷GUI toolkitµÄ±È½Ï (2)
Ç°ÃæÎÒÃÇ¿´µ½ÁËһЩRubyÖÐGUI±à³ÌÖг£¼ûµÄ¿âºÍËüÃǵÄRuby°ó¶¨°æ±¾£¨ÔÚRubyÖÐʹÓÃÓÃCÓïÑÔдµÄ¶«Î÷ÕæµÄÊÇÌ«¼òµ¥ÁË£©£¬ÏÂÃæ£¬»¹Òª½éÉÜÁíÍ⼸¸ö¡£Ç°ÎÄÊÇ·ÒëµÄ£¬±¾ÎÄÊÇ×Ô¼ºÕûÀíµÄ¡£
²é¿´È«ÎÄ25 11, 2004
RubyÖи÷GUI toolkitµÄ±È½Ï (1)
24 11, 2004
Ruby£«oracleÉú³ÉxmlÎĵµ
Ëæ×ÅRubyµÄÆÕ¼°£¬Ó¦ÓÃÒ²Ô½À´Ô½¹ã·º£¬µ±È»ÉÙ²»ÁËÊý¾Ý¿â±à³ÌÁË¡£
аæwindowsµÄone-click-installerµÄRuby°üº¬ÁËoracleµÄÖ§³Ö
£¨ÎÒµÃÊý¾Ý¿âΪoracle 8.1.6£©
²é¿´È«ÎÄ23 11, 2004
¿éºÍ±Õ°ü(block and Closures)
¿é£¨block£©£ºÒ»¶Î´úÂ룬Ï൱ÓÚÒ»¸öÄäÃûº¯Êý
±Õ°ü£¨Closures£©£ºÒ»¶Î´úÂ룬ÄÜ×÷Ϊ²ÎÊý´«µÝ¸øÆäËü·½·¨
²é¿´È«ÎÄ22 11, 2004
[ARTICLE] Extending Ruby with C
An article from Garrett Rooney just appeared at OnLamp.com
you can read it at
http://www.onlamp.com/pub/a/onlamp/2004/11/18/extending_ruby.html
19 11, 2004
ʲôÊÇ»ìºÏ²åÈ루mix-in£©
Ò»¸ömix-inÒ²ÊÇÒ»¸öÄ£¿é£¬ËüÄÜÊDZðµÄÀàÄÜÔö¼ÓÆäËüµÄ¹¦ÄÜ¡£
²é¿´È«ÎÄ19 11, 2004
privateºÍProtectedµÄÇø±ð
19 11, 2004
ÈçºÎÈ·±£¶ÁÍê¹Ø±ÕÎļþ£¿
19 11, 2004
´´½¨Ãû×ֿռ䣨namespaces£©
19 11, 2004
RubyºÍÆäËüÀàËÆÓïÑÔµÄÒ»µã±È½Ï
19 11, 2004
RubyÓÃÔÚÄÄÀï
17 11, 2004
[ ×ªÔØ ] žéʲüN Ruby
²é¿´È«ÎÄ
11 11, 2004
RubyÖÐÊÇ·ñ´æÔÚÖÐÎÄÎÊÌâ
11 11, 2004
YAML ºÍ Ruby
10 11, 2004
Ruby1.8.2-14 RC9 with RubyGems windows °²×° ·¢²¼
http://rubyforge.org/frs/?group_id=167
¸üмǼ£º
²é¿´È«ÎÄ8 11, 2004
RubyÖеÄÊý¾Ý¿â½Ó¿Ú
¸Éʲô¶¼Àë²»¿ªÊý¾Ý¿â£¬rubyÒ²ÊÇ£¬µ±ÈÃÒ²ÓÐÊý¾Ý¿âµÄ½Ó¿Ú¡£ÕâÀïÖ÷Òª½éÉÜһЩ£¬°üÀ¨oracle£¬myssql
²é¿´È«ÎÄ5 11, 2004
ÖÕÓÚ¾ö¶¨°á¼ÒÁË
Ö÷Òª¹Ø×¢rubyÓïÑÔ¡£
4 11, 2004
RubyºÍweb
Ruby¶ÔºÜ¶àÈËÀ´Ëµ£¬Ò²ÐíÖ»Êǽű¾ÓïÑÔ£¬»òÕßÖ»ÊÇÍê³ÉЩ»ù±¾¹¦ÄÜ£¬ÎÒÃÇÖªµÀÒѾºÜ¶àÓÃRubyдµÄweb£¬ftp£¬smtp·þÎñÆ÷ÁË¡£È»¶ø£¬Äã»á·¢ÏÖ£¬ruby»¹ÄÜдcgiµÈͨÓóÌÐò£¬ÉõÖÁÌæ´úphp£¨µ±È»Ä¿Ç°À´Ëµ²»¿ÉÄÜÁË£¬¿´¿´phpµÄÓû§ºÍÈí¼þ¾ÍÖªµÀÁË£©¡£
http://blog.itpub.net/liubin
²é¿´È«ÎÄ4 11, 2004
Ruby-cn.org ¿ªÍ¨ÁË
RubyÊÇÒ»ÖÖ´¿ÃæÏò¶ÔÏóµÄ½Å±¾ÓïÑÔ£¬ÔÚ¹úÍâºÜÁ÷ÐС£
1 11, 2004
ÓÃRails´´½¨webÓ¦ÓÃ
RailsÊÇÒ»¸öopen sourceµÄʹÓÃRuby¿ª·¢webÓ¦ÓõĿò¼Ü£¬Ëü²ÉÓÃÁËÁ÷ÐеÄMVCģʽ£¬±¾ÎĽéÉÜÁËÒ»¸ö¼òµ¥µÄ»ùÓÚÊý¾Ý¿âµÄwebÓ¦ÓõĿª·¢¡£
·Òë×Ô http://www.rubyonrails.org/show/TutorialStepOne
·Òë http://www.ruby-cn.org