Add RegistryAccess for managing registries

This commit is contained in:
Jake Potrebic
2022-03-02 13:36:21 -08:00
parent 41efb5322e
commit 25c065b4b2
12 changed files with 238 additions and 79 deletions

View File

@@ -0,0 +1,20 @@
package io.papermc.paper.registry;
import org.bukkit.Keyed;
import org.bukkit.Registry;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
public class TestRegistryAccess implements RegistryAccess {
@Override
@Deprecated(since = "1.20.6", forRemoval = true)
public @Nullable <T extends Keyed> Registry<T> getRegistry(final @NotNull Class<T> type) {
throw new UnsupportedOperationException("Not supported");
}
@Override
public @NotNull <T extends Keyed> Registry<T> getRegistry(final @NotNull RegistryKey<T> registryKey) {
throw new UnsupportedOperationException("Not supported");
}
}