wait in ruby 
Author Message
 wait in ruby

Hi,

next question from me :)

Is there a possibility to say ruby wait for exact 5m and then go on?

Thanks

Gustav



Fri, 05 Aug 2005 23:54:46 GMT  
 wait in ruby

G> Is there a possibility to say ruby wait for exact 5m and then go on?

 Kernel::sleep

pigeon% ri Kernel::sleep
---------------------------------------------------------- Kernel::sleep
     sleep( [aNumeric] ) -> aFixnum
------------------------------------------------------------------------
     Suspends the current thread for aNumber seconds (which may be a
     Float with fractional seconds). Returns the actual number of
     seconds slept (rounded), which may be less than that asked for if
     the thread was interrupted by a SIGALRM, or if another thread calls
     Thread#run. An argument of zero causes sleep to sleep forever.
        Time.new    #=> Sun Mar 04 23:30:41 CST 2001
        sleep 1.2   #=> 2
        Time.new    #=> Sun Mar 04 23:30:43 CST 2001
        sleep 1.9   #=> 2
        Time.new    #=> Sun Mar 04 23:30:45 CST 2001

pigeon%

Guy Decoux



Sat, 06 Aug 2005 00:10:34 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. interfacing non-WAIT state cpu buses to slow peripherals with WAIT signal

2. pthread trouble with ruby-opengl on FreeBSD (was: Re: [announcement] Ruby 3D Ruby)

3. Ruby books (Ruby NG FAQ, Ruby FAQ, home page)

4. RFD: comp.lang.ruby (getting Ruby out of comp.lang.misc)

5. Ruby: Ruby/Tk widget demo

6. ruby-lang.en older than ruby-lang.ja

7. Ruby/Tk update (for Ruby 1.8.x)

8. Ruby-GOME2-0.5.0, Ruby/GtkSourceView-0.1.0

9. RUBY NEWSGROUP FAQ -- Welcome to comp.lang.ruby!

10. Ruby Tuesday - Sydney Ruby Users' Group Meeting

11. RUBY NEWSGROUP FAQ -- Welcome to comp.lang.ruby!

 

 
Powered by phpBB® Forum Software