org.compass.needle.coherence
Class DefaultCoherenceLockFactory.CoherenceLock

java.lang.Object
  extended by org.apache.lucene.store.Lock
      extended by org.compass.needle.coherence.DefaultCoherenceLockFactory.CoherenceLock
Enclosing class:
DefaultCoherenceLockFactory

public class DefaultCoherenceLockFactory.CoherenceLock
extends Lock


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.lucene.store.Lock
Lock.With
 
Field Summary
 
Fields inherited from class org.apache.lucene.store.Lock
failureReason, LOCK_OBTAIN_WAIT_FOREVER, LOCK_POLL_INTERVAL
 
Constructor Summary
DefaultCoherenceLockFactory.CoherenceLock(String lockName)
           
 
Method Summary
 boolean isLocked()
           
 boolean obtain()
           
 boolean obtain(long lockWaitTimeout)
           
 void release()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultCoherenceLockFactory.CoherenceLock

public DefaultCoherenceLockFactory.CoherenceLock(String lockName)
Method Detail

isLocked

public boolean isLocked()
Specified by:
isLocked in class Lock

obtain

public boolean obtain()
               throws IOException
Specified by:
obtain in class Lock
Throws:
IOException

obtain

public boolean obtain(long lockWaitTimeout)
               throws LockObtainFailedException,
                      IOException
Overrides:
obtain in class Lock
Throws:
LockObtainFailedException
IOException

release

public void release()
Specified by:
release in class Lock


Copyright (c) 2004-2008 The Compass Project.