org.apache.cassandra.serializers

## Class BytesSerializer

- java.lang.Object
- - org.apache.cassandra.serializers.BytesSerializer

All Implemented Interfaces:
  TypeSerializer<java.nio.ByteBuffer>

Direct Known Subclasses:
  TupleSerializer, UserTypeSerializer

    public class BytesSerializer
    extends java.lang.Object
    implements TypeSerializer<java.nio.ByteBuffer>

### Field Summary

Fields
`static BytesSerializer` `instance`

### Constructor Summary

Constructors
Constructor and Description
`BytesSerializer()`

### Method Summary

All Methods Instance Methods Concrete Methods
`java.nio.ByteBuffer` `deserialize(java.nio.ByteBuffer value)`
`java.lang.Class<java.nio.ByteBuffer>` `getType()`
`java.nio.ByteBuffer` `serialize(java.nio.ByteBuffer bytes)`
`java.lang.String` `toString(java.nio.ByteBuffer value)`
`void` `validate(java.nio.ByteBuffer bytes)`

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

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

### Field Detail

#### instance

    public static final BytesSerializer instance

### Constructor Detail

#### BytesSerializer

    public BytesSerializer()

### Method Detail

#### serialize

    public java.nio.ByteBuffer serialize(java.nio.ByteBuffer bytes)

Specified by:
  `serialize` in interface `TypeSerializer<java.nio.ByteBuffer>`

#### deserialize

    public java.nio.ByteBuffer deserialize(java.nio.ByteBuffer value)

Specified by:
  `deserialize` in interface `TypeSerializer<java.nio.ByteBuffer>`

#### validate

    public void validate(java.nio.ByteBuffer bytes)
                  throws MarshalException

Specified by:
  `validate` in interface `TypeSerializer<java.nio.ByteBuffer>`
Throws:
  `MarshalException`

#### toString

    public java.lang.String toString(java.nio.ByteBuffer value)

Specified by:
  `toString` in interface `TypeSerializer<java.nio.ByteBuffer>`

#### getType

    public java.lang.Class<java.nio.ByteBuffer> getType()

Specified by:
  `getType` in interface `TypeSerializer<java.nio.ByteBuffer>`