superclass=Queue
type=class
library=thread
extended=
included=

κͤǤ [[c:Queue]] Ǥ

=== 

[[ruby-list:283]]ꡣq 򥵥 1  SizedQueue ֥Ȥ
뤳ȤˤäơϤԤȽϤԤƱˤʤޤ
q = [] ˤϤȰäǹԤϤޤ

  require 'thread'

  q = SizedQueue.new(1)

  th = Thread.start {
    while line = q.pop
      print line
    end
  }

  while l = gets
    q.push(l)
  end
  q.push(l)

  th.join
