Package org.eclipse.emf.spi.cdo

# Interface CDOLockStateCache

All Superinterfaces:
  `org.eclipse.net4j.util.lifecycle.IDeactivateable`, `org.eclipse.net4j.util.lifecycle.ILifecycle`, `org.eclipse.net4j.util.event.INotifier`

public interface CDOLockStateCache extends org.eclipse.net4j.util.lifecycle.ILifecycle
An optimized cache for `lock states` in the context of an entire `session`.

Since:
  4.15
Author:
  Eike Stepper
No Implement
  This interface is not intended to be implemented by clients.
No Extend
  This interface is not intended to be extended by clients.

## Nested Class Summary

Nested Classes
Modifier and Type
Interface
Description
`static final class`
`CDOLockStateCache.ObjectAlreadyLockedException`
An `IllegalStateException` thrown from `CDOLockStateCache` instances when a lock could not be obtained.

## Nested classes/interfaces inherited from interface org.eclipse.net4j.util.lifecycle.ILifecycle

`org.eclipse.net4j.util.lifecycle.ILifecycle.DeferrableActivation`

## Nested classes/interfaces inherited from interface org.eclipse.net4j.util.event.INotifier

`org.eclipse.net4j.util.event.INotifier.INotifier2`

## Method Summary

Modifier and Type
Method
Description
`void`
`addLockStates(CDOBranch branch, Collection<? extends CDOLockState> newLockStates, Consumer<CDOLockState> consumer)`
`Object`
`createKey(CDOBranch branch, CDOID id)`
`void`
`forEachLockState(CDOBranch branch, CDOLockOwner owner, Consumer<CDOLockState> consumer)`
`CDOLockState`
`getLockState(CDOBranch branch, CDOID id)`
`void`
`getLockStates(CDOBranch branch, Collection<CDOID> ids, boolean loadOnDemand, Consumer<CDOLockState> consumer)`
`InternalCDOSession`
`getSession()`
`void`
`remapOwner(CDOBranch branch, CDOLockOwner oldOwner, CDOLockOwner newOwner)`
`void`
`removeLockStates(CDOBranch branch)`
`void`
`removeLockStates(CDOBranch branch, Collection<CDOID> ids, Consumer<CDOLockState> consumer)`
`List<CDOLockDelta>`
`removeOwner(CDOBranch branch, CDOLockOwner owner, Consumer<CDOLockState> consumer)`
`void`
`updateLockStates(CDOBranch branch, Collection<CDOLockDelta> lockDeltas, Collection<CDOLockState> lockStates, Consumer<CDOLockState> consumer)`

### Methods inherited from interface org.eclipse.net4j.util.lifecycle.ILifecycle

`activate, deactivate, getLifecycleState, isActive`

### Methods inherited from interface org.eclipse.net4j.util.event.INotifier

`addListener, getListeners, hasListeners, removeListener`

## Method Details

### getSession

InternalCDOSession getSession()

### createKey

Object createKey(CDOBranch branch, CDOID id)

### getLockState

CDOLockState getLockState(CDOBranch branch, CDOID id)

### getLockStates

void getLockStates(CDOBranch branch, Collection<CDOID> ids, boolean loadOnDemand, Consumer<CDOLockState> consumer)

### forEachLockState

void forEachLockState(CDOBranch branch, CDOLockOwner owner, Consumer<CDOLockState> consumer)

### addLockStates

void addLockStates(CDOBranch branch, Collection<? extends CDOLockState> newLockStates, Consumer<CDOLockState> consumer)

### updateLockStates

void updateLockStates(CDOBranch branch, Collection<CDOLockDelta> lockDeltas, Collection<CDOLockState> lockStates, Consumer<CDOLockState> consumer)

### removeLockStates

void removeLockStates(CDOBranch branch, Collection<CDOID> ids, Consumer<CDOLockState> consumer)

### removeLockStates

void removeLockStates(CDOBranch branch)

### removeOwner

List<CDOLockDelta> removeOwner(CDOBranch branch, CDOLockOwner owner, Consumer<CDOLockState> consumer)

### remapOwner

void remapOwner(CDOBranch branch, CDOLockOwner oldOwner, CDOLockOwner newOwner)