Table of Contents

Class NbtLongArray

Namespace
fNbt
Assembly
fNbt.dll

A tag containing an array of signed 64-bit integers.

public sealed class NbtLongArray : NbtTag, ICloneable
Inheritance
NbtLongArray
Implements
Inherited Members

Constructors

NbtLongArray()

Creates an unnamed NbtLongArray tag, containing an empty array of longs.

public NbtLongArray()

NbtLongArray(long[])

Creates an unnamed NbtLongArray tag, containing the given array of longs.

public NbtLongArray(long[] value)

Parameters

value long[]

Long array to assign to this tag's Value. May not be null.

Remarks

Given long array will be cloned. To avoid unnecessary copying, call one of the other constructor overloads (that do not take a long[]) and then set the Value property yourself.

Exceptions

ArgumentNullException

value is null.

NbtLongArray(string?)

Creates an NbtLongArray tag with the given name, containing an empty array of longs.

public NbtLongArray(string? tagName)

Parameters

tagName string

Name to assign to this tag. May be null.

NbtLongArray(string?, long[])

Creates an NbtLongArray tag with the given name, containing the given array of longs.

public NbtLongArray(string? tagName, long[] value)

Parameters

tagName string

Name to assign to this tag. May be null.

value long[]

Long array to assign to this tag's Value. May not be null.

Remarks

Given long array will be cloned. To avoid unnecessary copying, call one of the other constructor overloads (that do not take a long[]) and then set the Value property yourself.

Exceptions

ArgumentNullException

value is null.

NbtLongArray(NbtLongArray)

Creates a deep copy of given NbtLongArray.

public NbtLongArray(NbtLongArray other)

Parameters

other NbtLongArray

Tag to copy. May not be null.

Remarks

Long array of given tag will be cloned.

Exceptions

ArgumentNullException

other is null.

Properties

this[int]

Gets or sets a long at the given index.

public long this[int index] { get; set; }

Parameters

index int

The zero-based index of the element to get or set.

Property Value

long

The long at the specified index.

Exceptions

IndexOutOfRangeException

index is outside the array bounds.

TagType

Type of this tag (LongArray).

public override NbtTagType TagType { get; }

Property Value

NbtTagType

Value

Value/payload of this tag (an array of signed 64-bit integers). Value is stored as-is and is NOT cloned. May not be null.

public long[] Value { get; set; }

Property Value

long[]

Exceptions

ArgumentNullException

value is null.

Methods

Clone()

Creates a deep copy of this tag.

public override object Clone()

Returns

object

A new NbtTag object that is a deep copy of this instance.