SharedQueue.st
changeset 14 ca0b5fbc8131
parent 6 96ce41566060
child 30 f34b335ac2d7
equal deleted inserted replaced
13:f089ff744cd1 14:ca0b5fbc8131
    19 SharedQueue comment:'
    19 SharedQueue comment:'
    20 SharedQueues provide a safe mechanism for processes to communicate.
    20 SharedQueues provide a safe mechanism for processes to communicate.
    21 
    21 
    22 See samples in doc/coding.
    22 See samples in doc/coding.
    23 
    23 
    24 $Header: /cvs/stx/stx/libbasic2/SharedQueue.st,v 1.4 1993-11-08 02:31:55 claus Exp $
    24 $Header: /cvs/stx/stx/libbasic2/SharedQueue.st,v 1.5 1994-01-09 21:24:30 claus Exp $
    25 
    25 
    26 '!
    26 '!
    27 
    27 
    28 !SharedQueue methodsFor:'initialization'!
    28 !SharedQueue methodsFor:'initialization'!
    29 
    29 
    30 init:size
    30 init:size
       
    31     "initialize the receiver for size entries"
       
    32 
    31     super init:size.
    33     super init:size.
    32     accessProtect := Semaphore forMutualExclusion.
    34     accessProtect := Semaphore forMutualExclusion.
    33     dataAvailable := Semaphore new.
    35     dataAvailable := Semaphore new.
    34     spaceAvailable := Semaphore new
    36     spaceAvailable := Semaphore new
    35 ! !
    37 ! !