org.apache.solr.store.blockcache

## Class BlockCache

- java.lang.Object
- - org.apache.solr.store.blockcache.BlockCache

-     public class BlockCache
      extends Object

  WARNING: This API is experimental and might change in incompatible ways in the next release.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `_128M`
    `static int` | `_32K`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `BlockCache(Metrics metrics, boolean directAllocation, long totalMemory)`
    `BlockCache(Metrics metrics, boolean directAllocation, long totalMemory, int slabSize)`
    `BlockCache(Metrics metrics, boolean directAllocation, long totalMemory, int slabSize, int blockSize)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `fetch(BlockCacheKey blockCacheKey, byte[] buffer)`
    `boolean` | `fetch(BlockCacheKey blockCacheKey, byte[] buffer, int blockOffset, int off, int length)`
    `int` | `getSize()`
    `void` | `release(BlockCacheKey key)`
    `boolean` | `store(BlockCacheKey blockCacheKey, int blockOffset, byte[] data, int offset, int length)`

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

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

- - ### Field Detail

    - #### _128M

          public static final int _128M

      See Also:
        Constant Field Values

    - #### _32K

          public static final int _32K

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### BlockCache

          public BlockCache(Metrics metrics,
                            boolean directAllocation,
                            long totalMemory)

    - #### BlockCache

          public BlockCache(Metrics metrics,
                            boolean directAllocation,
                            long totalMemory,
                            int slabSize)

    - #### BlockCache

          public BlockCache(Metrics metrics,
                            boolean directAllocation,
                            long totalMemory,
                            int slabSize,
                            int blockSize)

  - ### Method Detail

    - #### release

          public void release(BlockCacheKey key)

    - #### store

          public boolean store(BlockCacheKey blockCacheKey,
                               int blockOffset,
                               byte[] data,
                               int offset,
                               int length)

    - #### fetch

          public boolean fetch(BlockCacheKey blockCacheKey,
                               byte[] buffer,
                               int blockOffset,
                               int off,
                               int length)

    - #### fetch

          public boolean fetch(BlockCacheKey blockCacheKey,
                               byte[] buffer)

    - #### getSize

          public int getSize()

Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.