Package org.apache.qpid.proton.amqp

# Class Binary

java.lang.Object
org.apache.qpid.proton.amqp.Binary

public final class Binary extends Object

## Constructor Summary

Constructors
Constructor
Description
`Binary(byte[] data)`
`Binary(byte[] data, int offset, int length)`

## Method Summary

Modifier and Type
Method
Description
`ByteBuffer`
`asByteBuffer()`
`static Binary`
`combine(Collection<Binary> binaries)`
`static Binary`
`copy(Binary source)`
`static Binary`
`create(ByteBuffer buffer)`
`static Binary`
`create(ReadableBuffer buffer)`
`final boolean`
`equals(Object o)`
`byte[]`
`getArray()`
`int`
`getArrayOffset()`
`int`
`getLength()`
`final int`
`hashCode()`
`Binary`
`subBinary(int offset, int length)`
`String`
`toString()`

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

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

## Constructor Details

### Binary

public Binary(byte[] data)

### Binary

public Binary(byte[] data, int offset, int length)

## Method Details

### asByteBuffer

public ByteBuffer asByteBuffer()

### hashCode

public final int hashCode()

Overrides:
  `hashCode` in class `Object`

### equals

public final boolean equals(Object o)

Overrides:
  `equals` in class `Object`

### getArrayOffset

public int getArrayOffset()

### getArray

public byte[] getArray()

### getLength

public int getLength()

### toString

public String toString()

Overrides:
  `toString` in class `Object`

### combine

public static Binary combine(Collection<Binary> binaries)

### subBinary

public Binary subBinary(int offset, int length)

### create

public static Binary create(ReadableBuffer buffer)

### create

public static Binary create(ByteBuffer buffer)

### copy

public static Binary copy(Binary source)