Commits

Bjarne Koll authored and md_5 committed 2b198268e93
#933: Define native persistent data types for lists
No tags

src/main/java/org/bukkit/persistence/ListPersistentDataType.java

Added
1 +package org.bukkit.persistence;
2 +
3 +import java.util.List;
4 +import org.jetbrains.annotations.NotNull;
5 +
6 +/**
7 + * The list persistent data represents a data type that is capable of storing a
8 + * list of other data types in a {@link PersistentDataContainer}.
9 + *
10 + * @param <P> the primitive type of the list element.
11 + * @param <C> the complex type of the list elements.
12 + */
13 +public interface ListPersistentDataType<P, C> extends PersistentDataType<List<P>, List<C>> {
14 +
15 + /**
16 + * Provides the persistent data type of the elements found in the list.
17 + *
18 + * @return the persistent data type.
19 + */
20 + @NotNull
21 + PersistentDataType<P, C> elementType();
22 +}

Everything looks good. We'll let you know here if there's anything you should know about.

Add shortcut