Packages

final class UnsafeArrayData extends ArrayData with Externalizable with KryoSerializable

An Unsafe implementation of Array which is backed by raw memory instead of Java objects.

Each array has four parts: [numElements][null bits][values or offset&length][variable length portion]

The numElements is 8 bytes storing the number of elements of this array.

In the null bits region, we store 1 bit per element, represents whether an element is null Its total size is ceil(numElements / 8) bytes, and it is aligned to 8-byte boundaries.

In the values or offset&length region, we store the content of elements. For fields that hold fixed-length primitive types, such as long, double, or int, we store the value directly in the field. The whole fixed-length portion (even for byte) is aligned to 8-byte boundaries. For fields with non-primitive or variable-length values, we store a relative offset (w.r.t. the base address of the array) that points to the beginning of the variable-length field and length (they are combined into a long). For variable length portion, each is aligned to 8-byte boundaries.

Instances of UnsafeArrayData act as pointers to row data stored in this format.

Linear Supertypes
KryoSerializable, Externalizable, ArrayData, Serializable, Serializable, SpecializedGetters, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. UnsafeArrayData
  2. KryoSerializable
  3. Externalizable
  4. ArrayData
  5. Serializable
  6. Serializable
  7. SpecializedGetters
  8. AnyRef
  9. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new UnsafeArrayData()

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def array(): Array[AnyRef]
    Definition Classes
    UnsafeArrayDataArrayData
  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @HotSpotIntrinsicCandidate()
  7. def copy(): UnsafeArrayData
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  8. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  9. def equals(other: Any): Boolean
    Definition Classes
    UnsafeArrayData → AnyRef → Any
    Annotations
    @Override()
  10. def foreach(elementType: DataType, f: (Int, Any) ⇒ Unit): Unit
    Definition Classes
    ArrayData
  11. def get(ordinal: Int, dataType: DataType): AnyRef
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  12. def getArray(ordinal: Int): UnsafeArrayData
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  13. def getBaseObject(): AnyRef
  14. def getBaseOffset(): Long
  15. def getBinary(ordinal: Int): Array[Byte]
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  16. def getBoolean(ordinal: Int): Boolean
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  17. def getByte(ordinal: Int): Byte
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  18. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  19. def getDecimal(ordinal: Int, precision: Int, scale: Int): Decimal
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  20. def getDouble(ordinal: Int): Double
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  21. def getFloat(ordinal: Int): Float
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  22. def getInt(ordinal: Int): Int
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  23. def getInterval(ordinal: Int): CalendarInterval
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  24. def getLong(ordinal: Int): Long
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  25. def getMap(ordinal: Int): UnsafeMapData
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  26. def getShort(ordinal: Int): Short
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  27. def getSizeInBytes(): Int
  28. def getStruct(ordinal: Int, numFields: Int): UnsafeRow
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  29. def getUTF8String(ordinal: Int): UTF8String
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  30. def hashCode(): Int
    Definition Classes
    UnsafeArrayData → AnyRef → Any
    Annotations
    @Override()
  31. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  32. def isNullAt(ordinal: Int): Boolean
    Definition Classes
    UnsafeArrayDataSpecializedGetters
    Annotations
    @Override()
  33. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  34. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  35. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  36. def numElements(): Int
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  37. def pointTo(baseObject: Any, baseOffset: Long, sizeInBytes: Int): Unit

    Update this UnsafeArrayData to point to different backing data.

    Update this UnsafeArrayData to point to different backing data.

    baseObject

    the base object

    baseOffset

    the offset within the base object

    sizeInBytes

    the size of this array's backing data, in bytes

  38. def read(kryo: Kryo, input: Input): Unit
    Definition Classes
    UnsafeArrayData → KryoSerializable
    Annotations
    @Override()
  39. def readExternal(in: ObjectInput): Unit
    Definition Classes
    UnsafeArrayData → Externalizable
    Annotations
    @Override()
  40. def setBoolean(ordinal: Int, value: Boolean): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  41. def setByte(ordinal: Int, value: Byte): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  42. def setDouble(ordinal: Int, value: Double): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  43. def setFloat(ordinal: Int, value: Float): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  44. def setInt(ordinal: Int, value: Int): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  45. def setLong(ordinal: Int, value: Long): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  46. def setNullAt(ordinal: Int): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  47. def setShort(ordinal: Int, value: Short): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  48. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  49. def toArray[T](elementType: DataType)(implicit arg0: ClassTag[T]): Array[T]
    Definition Classes
    ArrayData
  50. def toBooleanArray(): Array[Boolean]
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  51. def toByteArray(): Array[Byte]
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  52. def toDoubleArray(): Array[Double]
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  53. def toFloatArray(): Array[Float]
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  54. def toIntArray(): Array[Int]
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  55. def toLongArray(): Array[Long]
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  56. def toObjectArray(elementType: DataType): Array[AnyRef]
    Definition Classes
    ArrayData
  57. def toSeq[T](dataType: DataType): IndexedSeq[T]
    Definition Classes
    ArrayData
  58. def toShortArray(): Array[Short]
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  59. def toString(): String
    Definition Classes
    AnyRef → Any
  60. def update(ordinal: Int, value: Any): Unit
    Definition Classes
    UnsafeArrayDataArrayData
    Annotations
    @Override()
  61. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  62. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  63. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  64. def write(kryo: Kryo, output: Output): Unit
    Definition Classes
    UnsafeArrayData → KryoSerializable
    Annotations
    @Override()
  65. def writeExternal(out: ObjectOutput): Unit
    Definition Classes
    UnsafeArrayData → Externalizable
    Annotations
    @Override()
  66. def writeTo(buffer: ByteBuffer): Unit
  67. def writeToMemory(target: Any, targetOffset: Long): Unit

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] ) @Deprecated
    Deprecated

Inherited from KryoSerializable

Inherited from Externalizable

Inherited from ArrayData

Inherited from Serializable

Inherited from Serializable

Inherited from SpecializedGetters

Inherited from AnyRef

Inherited from Any

Ungrouped