Example usage for org.apache.spark.unsafe Platform LONG_ARRAY_OFFSET

List of usage examples for org.apache.spark.unsafe Platform LONG_ARRAY_OFFSET

Introduction

In this page you can find the example usage for org.apache.spark.unsafe Platform LONG_ARRAY_OFFSET.

Prototype

int LONG_ARRAY_OFFSET

To view the source code for org.apache.spark.unsafe Platform LONG_ARRAY_OFFSET.

Click Source Link

Usage

From source file:org.apache.carbondata.core.memory.MemoryBlock.java

License:Apache License

/**
 * Creates a memory block pointing to the memory used by the long array.
 *///from  w w w  .  jav  a  2 s.  c o  m
public static MemoryBlock fromLongArray(final long[] array) {
    return new MemoryBlock(array, Platform.LONG_ARRAY_OFFSET, array.length * 8);
}