Skip to content

Commit 6e5dede

Browse files
committed
Expand NBTElement documentation with parent/child constraints
1 parent c2dd07b commit 6e5dede

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

‎src/main/java/org/glavo/nbt/NBTElement.java‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,12 @@
2525

2626
/// Base interface for all NBT elements.
2727
///
28+
/// An NBT element may be a child element of an [NBTParent] (such as a [CompoundTag][org.glavo.nbt.tag.CompoundTag] or [ListTag][org.glavo.nbt.tag.ListTag]).
29+
///
30+
/// Each NBT element has a unique position in the entire tree:
31+
/// It can have at most one parent and cannot belong to multiple parents simultaneously;
32+
/// and it cannot be multiple children of the same parent at the same time.
33+
///
2834
/// @see Tag
2935
/// @see ChunkRegion
3036
/// @see Chunk

0 commit comments

Comments
 (0)