Class CDORevisionManager.Request.Config

java.lang.Object
org.eclipse.emf.cdo.common.revision.CDORevisionManager.Request.Config
Enclosing interface:
CDORevisionManager.Request

public static final class CDORevisionManager.Request.Config extends Object
Immutable loading options shared by revision manager operations and modern revision loaders. The configuration is intentionally a superset: an operation or loader ignores options that it does not support. The collection policy is retained by reference, so concurrent reuse of a configuration also requires that policy implementation to be thread-safe.
Since:
4.37
Author:
Eike Stepper
  • Field Details

    • DEFAULT

      public static final CDORevisionManager.Request.Config DEFAULT
      The default revision-loading configuration: cache then loader, no containment or lock-state prefetch, and the effective session collection policy.
      Since:
      4.37
    • REFERENCE_CHUNK_UNSPECIFIED

      public static final int REFERENCE_CHUNK_UNSPECIFIED
      See Also:
  • Constructor Details

    • Config

      public Config(CDORevisionManager.Request.Config.LookupMode lookupMode, int prefetchDepth, boolean prefetchLockStates)
      Creates an immutable configuration using an unchunked scalar reference chunk.
      Parameters:
      lookupMode - the source-selection mode
      prefetchDepth - the containment prefetch depth
      prefetchLockStates - whether lock states are prefetched where supported
    • Config

      public Config(CDORevisionManager.Request.Config.LookupMode lookupMode, int prefetchDepth, boolean prefetchLockStates, int referenceChunk)
      Creates an immutable configuration.
      Parameters:
      lookupMode - the source-selection mode
      prefetchDepth - the containment prefetch depth; operations without containment prefetch support ignore it
      prefetchLockStates - whether lock states are prefetched where supported
      referenceChunk - the scalar reference chunk for legacy loading paths
  • Method Details

    • getLookupMode

      Returns the lookup mode.
      Returns:
      the cache and loader source-selection mode
    • getPrefetchDepth

      public int getPrefetchDepth()
      Returns the containment prefetch depth, which is ignored by operations that do not support containment prefetch.
      Returns:
      the number of containment levels to prefetch, or a CDORevision depth constant
    • isPrefetchLockStates

      public boolean isPrefetchLockStates()
      Returns whether lock states should be prefetched where supported.
      Returns:
      true if lock states should be prefetched
    • getReferenceChunk

      public int getReferenceChunk()
      Returns the scalar reference chunk for legacy loading paths.
      Returns:
      the scalar reference chunk