Perl Cd Bookshelf [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Perl Cd Bookshelf [Electronic resources] - نسخه متنی

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید



8.211. Thread::Queue


Provides a thread-safe queue. Any
number of threads can add elements to the end of the queue or remove
elements from the head.

new


$q = new Thread::Queue

Creates a new empty queue. Returns an object representing the queue.

dequeue


$q->dequeue

Removes and returns a scalar from the head of the queue. If the queue
is empty, dequeue blocks the thread until another
thread enqueue s a scalar on the queue.

dequeue_nb


$q->dequeue_nb

Like dequeue, but returns undef
if the queue is empty instead of blocking.

enqueue


$q->enqueue list

Adds the list of scalars, list, to the end
of the queue.

pending


$q->pending

Returns the number of items remaining in the queue.



8.210. Thread8.212. Thread::Semaphore




Copyright © 2002 O'Reilly & Associates. All rights reserved.

/ 875