org.apache.cassandra.io.sstable

## Class ColumnNameHelper

- java.lang.Object
- - org.apache.cassandra.io.sstable.ColumnNameHelper

    public class ColumnNameHelper
    extends java.lang.Object

### Constructor Summary

Constructors
Constructor and Description
`ColumnNameHelper()`

### Method Summary

Methods

`static java.util.List<java.nio.ByteBuffer>`

`maxComponents(java.util.List<java.nio.ByteBuffer> maxSeen, java.nio.ByteBuffer candidate, AbstractType<?> comparator)`
finds the max column name(s) if comparator is of CompositeType, candidate will be split into its components, and each component is compared to the component on the same place in maxSeen, and then returning the list with the max columns.

`static java.util.List<java.nio.ByteBuffer>` `mergeMax(java.util.List<java.nio.ByteBuffer> maxColumnNames, java.util.List<java.nio.ByteBuffer> candidates, AbstractType<?> columnNameComparator)` if columnNameComparator is CompositeType the columns are compared by components using the subcomparator on the same position.
`static java.util.List<java.nio.ByteBuffer>` `mergeMin(java.util.List<java.nio.ByteBuffer> minColumnNames, java.util.List<java.nio.ByteBuffer> candidates, AbstractType<?> columnNameComparator)` if columnNameComparator is CompositeType the columns are compared by components using the subcomparator on the same position.

`static java.util.List<java.nio.ByteBuffer>`

`minComponents(java.util.List<java.nio.ByteBuffer> minSeen, java.nio.ByteBuffer candidate, AbstractType<?> comparator)`
finds the min column name(s) if comparator is of CompositeType, candidate will be split into its components, and each component is compared to the component on the same place in minSeen, and then returning the list with the min columns.

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

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

### Constructor Detail

#### ColumnNameHelper

    public ColumnNameHelper()

### Method Detail

#### maxComponents

    public static java.util.List<java.nio.ByteBuffer> maxComponents(java.util.List<java.nio.ByteBuffer> maxSeen,
                                                    java.nio.ByteBuffer candidate,
                                                    AbstractType<?> comparator)

finds the max column name(s) if comparator is of CompositeType, candidate will be split into its components, and each component is compared to the component on the same place in maxSeen, and then returning the list with the max columns. will collect at most the number of types in the comparator. if comparator is not CompositeType, maxSeen is assumed to be of size 1 and the item there is compared to the candidate.

Parameters:
  `maxSeen` - the max columns seen so far
  `candidate` - the candidate column(s)
  `comparator` - the comparator to use
Returns:
  a list with the max column(s)

#### minComponents

    public static java.util.List<java.nio.ByteBuffer> minComponents(java.util.List<java.nio.ByteBuffer> minSeen,
                                                    java.nio.ByteBuffer candidate,
                                                    AbstractType<?> comparator)

finds the min column name(s) if comparator is of CompositeType, candidate will be split into its components, and each component is compared to the component on the same place in minSeen, and then returning the list with the min columns. if comparator is not CompositeType, maxSeen is assumed to be of size 1 and the item there is compared to the candidate.

Parameters:
  `minSeen` - the max columns seen so far
  `candidate` - the candidate column(s)
  `comparator` - the comparator to use
Returns:
  a list with the min column(s)

#### mergeMin

    public static java.util.List<java.nio.ByteBuffer> mergeMin(java.util.List<java.nio.ByteBuffer> minColumnNames,
                                               java.util.List<java.nio.ByteBuffer> candidates,
                                               AbstractType<?> columnNameComparator)

if columnNameComparator is CompositeType the columns are compared by components using the subcomparator on the same position. if comparator is not CompositeType, the lists are assumed to be of max size 1 and compared using the comparator directly.

Parameters:
  `minColumnNames` - lhs
  `candidates` - rhs
  `columnNameComparator` - comparator to use
Returns:
  a list with smallest column names according to (sub)comparator

#### mergeMax

    public static java.util.List<java.nio.ByteBuffer> mergeMax(java.util.List<java.nio.ByteBuffer> maxColumnNames,
                                               java.util.List<java.nio.ByteBuffer> candidates,
                                               AbstractType<?> columnNameComparator)

if columnNameComparator is CompositeType the columns are compared by components using the subcomparator on the same position. if comparator is not CompositeType, the lists are assumed to be of max size 1 and compared using the comparator directly.

Parameters:
  `maxColumnNames` - lhs
  `candidates` - rhs
  `columnNameComparator` - comparator to use
Returns:
  a list with biggest column names according to (sub)comparator