cascading.util.cache

## Class BaseCacheFactory<Key,Value,Config>

- java.lang.Object
- - cascading.util.cache.BaseCacheFactory<Key,Value,Config>

- All Implemented Interfaces:
    CascadingFactory<Config,CascadingCache<Key,Value>>
  Direct Known Subclasses:
    DirectMappedCacheFactory, LRUHashMapCacheFactory, OrderedHashMapCacheFactory

      public abstract class BaseCacheFactory<Key,Value,Config>
      extends Object
      implements CascadingFactory<Config,CascadingCache<Key,Value>>

  Base class for all CacheFactories for creating `CascadingCache` instances. Each sub-assembly using the `CascadingCache` facilities has it's own sub-class of this factory so that different Caches can be used for different parts of the same flow.

  A `CacheEvictionCallback` can be set and it will be given to each Cache instance created by the factory. If none is set, the Factory will use `CacheEvictionCallback.NULL`, which is a no-op implementation of the `CacheEvictionCallback` interface.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `DEFAULT_CAPACITY` default capacity for all caches.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `BaseCacheFactory()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `abstract CascadingCache<Key,Value>` | `create(FlowProcess<? extends Config> flowProcess)` Method create will return a new instance of the type create by this factory.
    `void` | `initialize(FlowProcess<? extends Config> flowProcess)` Method initialize will configure an initialize this factory instance.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### DEFAULT_CAPACITY

          public static final int DEFAULT_CAPACITY

      default capacity for all caches.
      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### BaseCacheFactory

          public BaseCacheFactory()

  - ### Method Detail

    - #### initialize

          public void initialize(FlowProcess<? extends Config> flowProcess)

      Description copied from interface: `CascadingFactory`
      Method initialize will configure an initialize this factory instance.
      Specified by:
        `initialize` in interface `CascadingFactory<Config,CascadingCache<Key,Value>>`
      Parameters:
        `flowProcess` - of type FlowProcess

    - #### create

          public abstract CascadingCache<Key,Value> create(FlowProcess<? extends Config> flowProcess)

      Description copied from interface: `CascadingFactory`
      Method create will return a new instance of the type create by this factory.
      Specified by:
        `create` in interface `CascadingFactory<Config,CascadingCache<Key,Value>>`
      Parameters:
        `flowProcess` - of type FlowProcess
      Returns:
        of type Instance

Copyright © 2007-2015 Concurrent, Inc. All Rights Reserved.