org.apache.jackrabbit.core.state
Interface ISMLocking

All Known Implementing Classes:
DefaultISMLocking, FineGrainedISMLocking

public interface ISMLocking

ISMLocking defines an interface for a locking strategy of an ItemStateManager.

An implementation of ISMLocking must meet the following requirements:


Nested Class Summary
static interface ISMLocking.ReadLock
           
static interface ISMLocking.WriteLock
           
 
Method Summary
 ISMLocking.ReadLock acquireReadLock(ItemId id)
          Acquire a read lock for the given item id.
 ISMLocking.WriteLock acquireWriteLock(ChangeLog changeLog)
          Acquires a write lock for the given changeLog.
 

Method Detail

acquireReadLock

ISMLocking.ReadLock acquireReadLock(ItemId id)
                                    throws InterruptedException
Acquire a read lock for the given item id.

Parameters:
id - an item id.
Throws:
InterruptedException

acquireWriteLock

ISMLocking.WriteLock acquireWriteLock(ChangeLog changeLog)
                                      throws InterruptedException
Acquires a write lock for the given changeLog.

Parameters:
changeLog - the change log
Returns:
the write lock for the given changeLog.
Throws:
InterruptedException - if the thread is interrupted while creating the write lock.


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.