Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.gjt.sp.util
Class ReadWriteLock

    java.lang.Object
      org.gjt.sp.util.ReadWriteLock

public class ReadWriteLock
extends java.lang.Object

Implements consumer/producer locking scemantics.

Version:
  $Id: ReadWriteLock.java,v 1.7 2004/02/14 19:02:49 spestov Exp $ The lock tries to be re-entrant when called from the same thread in some cases. The following is ok: read lock read lock read unlock read unlock write lock read lock read unlock write unlock The following is not ok: read lock write lock write unlock read unlock write lock write lock write unlock write unlock
Author:
  Peter Graves

Constructor Summary
`ReadWriteLock()`

Method Summary
`boolean` | `isWriteLocked()`
`void` | `readLock()`
`void` | `readUnlock()`
`void` | `writeLock()`
`void` | `writeUnlock()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ReadWriteLock

    public ReadWriteLock()

Method Detail

### readLock

    public void readLock()

### readUnlock

    public void readUnlock()

### writeLock

    public void writeLock()

### writeUnlock

    public void writeUnlock()

### isWriteLocked

    public boolean isWriteLocked()

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD