## org.apache.cassandra.db.marshal
Class AbstractType

    java.lang.Object
      org.apache.cassandra.db.marshal.AbstractType

All Implemented Interfaces:
  java.util.Comparator<byte[]>

Direct Known Subclasses:
  BytesType, LexicalUUIDType, LongType, TimeUUIDType, UTF8Type

    public abstract class AbstractType

extends java.lang.Object
implements java.util.Comparator<byte[]>

Specifies a Comparator for a specific type of byte[]. Note that empty byte[] are used to represent "start at the beginning" or "stop at the end" arguments to get_slice, so the Comparator should always handle those values even if they normally do not represent a valid byte[] for the type being compared.

Constructor Summary
`AbstractType()`

Method Summary
`boolean` `equals(java.lang.Object obj)`
`java.lang.String` `getColumnsString(java.util.Collection<IColumn> columns)` convenience method
`java.util.Comparator<byte[]>` `getReverseComparator()`
`abstract java.lang.String` `getString(byte[] bytes)` get a string representation of the bytes suitable for log messages
`java.lang.String` `getString(java.util.Collection<byte[]> names)` convenience method
`void` `validate(byte[] bytes)` validate that the byte array is a valid sequence for the type we are supposed to be comparing

Methods inherited from class java.lang.Object
`clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface java.util.Comparator
`compare`

Constructor Detail

### AbstractType

    public AbstractType()

Method Detail

### getString

    public abstract java.lang.String getString(byte[] bytes)

  get a string representation of the bytes suitable for log messages

### validate

    public void validate(byte[] bytes)

  validate that the byte array is a valid sequence for the type we are supposed to be comparing

### getReverseComparator

    public java.util.Comparator<byte[]> getReverseComparator()

### getString

    public java.lang.String getString(java.util.Collection<byte[]> names)

  convenience method

### getColumnsString

    public java.lang.String getColumnsString(java.util.Collection<IColumn> columns)

  convenience method

### equals

    public final boolean equals(java.lang.Object obj)

  Specified by:
    `equals` in interface `java.util.Comparator<byte[]>`
  Overrides:
    `equals` in class `java.lang.Object`

Copyright © 2010 The Apache Software Foundation