CompoundComposite (apache-cassandra API)
Date: 2014-10-21

org.apache.cassandra.db.composites

## Class CompoundComposite

- java.lang.Object
- - org.apache.cassandra.db.composites.AbstractComposite
  - - org.apache.cassandra.db.composites.CompoundComposite

- All Implemented Interfaces:
    IMeasurableMemory, Composite
  Direct Known Subclasses:
    CompoundDenseCellName, CompoundSparseCellName

      public class CompoundComposite
      extends AbstractComposite

  A "truly-composite" Composite.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface org.apache.cassandra.db.composites.Composite

      `Composite.EOC`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `Composite` | `copy(CFMetaData cfm, AbstractAllocator allocator)`
    `protected java.nio.ByteBuffer[]` | `elementsCopy(AbstractAllocator allocator)`
    `java.nio.ByteBuffer` | `get(int i)`
    `boolean` | `isStatic()`
    `int` | `size()`
    `long` | `unsharedHeapSize()`
    `long` | `unsharedHeapSizeExcludingData()`

    - ### Methods inherited from class org.apache.cassandra.db.composites.AbstractComposite

      `dataSize, end, eoc, equals, hashCode, isEmpty, isPrefixOf, slice, start, toByteBuffer, withEOC`

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

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

- - ### Method Detail

    - #### size

          public int size()

    - #### get

          public java.nio.ByteBuffer get(int i)

    - #### isStatic

          public boolean isStatic()

      Specified by:
        `isStatic` in interface `Composite`
      Overrides:
        `isStatic` in class `AbstractComposite`

    - #### elementsCopy

          protected java.nio.ByteBuffer[] elementsCopy(AbstractAllocator allocator)

    - #### unsharedHeapSize

          public long unsharedHeapSize()

      Returns:
        the amount of on-heap memory retained by the object that might be reclaimed if the object were reclaimed, i.e. it should try to exclude globally cached data where possible, or counting portions of arrays that are referenced by the object but used by other objects only (e.g. slabbed byte-buffers), etc.

    - #### unsharedHeapSizeExcludingData

          public long unsharedHeapSizeExcludingData()

    - #### copy

          public Composite copy(CFMetaData cfm,
                       AbstractAllocator allocator)

Copyright © 2014 The Apache Software Foundation