org.apache.ignite.internal.mem

## Class UnsafeChunk

- java.lang.Object
- - org.apache.ignite.internal.mem.UnsafeChunk

All Implemented Interfaces:
  DirectMemoryRegion

    public class UnsafeChunk
    extends Object
    implements DirectMemoryRegion

### Constructor Summary

Constructors
Constructor and Description
`UnsafeChunk(long ptr, long len)`

### Method Summary

Methods
`long` `address()`
`long` `size()`
`DirectMemoryRegion` `slice(long offset)` Gets a sub-region of this region starting from the given offset.
`String` `toString()`

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

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

### Constructor Detail

#### UnsafeChunk

    public UnsafeChunk(long ptr,
               long len)

Parameters:
  `ptr` - Pointer to the memory start.
  `len` - Memory length.

### Method Detail

#### address

    public long address()

Specified by:
  `address` in interface `DirectMemoryRegion`
Returns:
  Region start address.

#### size

    public long size()

Specified by:
  `size` in interface `DirectMemoryRegion`
Returns:
  Region size.

#### slice

    public DirectMemoryRegion slice(long offset)

Gets a sub-region of this region starting from the given offset.

Specified by:
  `slice` in interface `DirectMemoryRegion`
Parameters:
  `offset` - Offset within this region.
Returns:
  Sub-region.

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

2017 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 2.2.0
Release Date | : September 15 2017