WrapType
wrap(IDataType
dataType) {
+ return new BukkitType1_19_R2<>(dataType);
+ }
+
+}
\ No newline at end of file
diff --git a/vcompat-1_19_R2/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R2/EntityProvider1_19_R2.java b/vcompat-1_19_R2/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R2/EntityProvider1_19_R2.java
new file mode 100644
index 0000000..d682b17
--- /dev/null
+++ b/vcompat-1_19_R2/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R2/EntityProvider1_19_R2.java
@@ -0,0 +1,47 @@
+package net.sourcewriters.minecraft.vcompat.provider.impl.v1_19_R2;
+
+import java.util.EnumMap;
+import java.util.function.Function;
+
+import org.bukkit.craftbukkit.v1_19_R2.CraftWorld;
+
+import net.minecraft.world.level.Level;
+import net.sourcewriters.minecraft.vcompat.provider.EntityProvider;
+import net.sourcewriters.minecraft.vcompat.provider.entity.NmsEntity;
+import net.sourcewriters.minecraft.vcompat.provider.entity.NmsEntityType;
+import net.sourcewriters.minecraft.vcompat.provider.impl.v1_19_R2.utils.EntityConstructors1_19_R2;
+
+public class EntityProvider1_19_R2 extends EntityProvider boolean has(String key, WrapType type) {
+ return has(wrappedKey(key), type);
+ }
+
+ @Override
+ public boolean has(WrappedKey> key, WrapType type) {
+ return container.has(key.getNamespacedKey(), type.syntaxType());
+ }
+
+ @Override
+ public Object get(String key) {
+ return get(wrappedKey(key));
+ }
+
+ @Override
+ public Object get(WrappedKey> key) {
+ return container.get(key.getNamespacedKey());
+ }
+
+ @Override
+ public C get(String key, WrapType type) {
+ return get(wrappedKey(key), type);
+ }
+
+ @Override
+ public C get(WrappedKey> key, WrapType type) {
+ return container.get(key.getNamespacedKey(), type.syntaxType());
+ }
+
+ @Override
+ public void set(String key, B value, WrapType, B> type) {
+ set(wrappedKey(key), value, type);
+ }
+
+ @Override
+ public void set(WrappedKey> key, B value, WrapType, B> type) {
+ container.set(key.getNamespacedKey(), value, type.syntaxType());
+ }
+
+ @Override
+ public boolean remove(String key) {
+ return false;
+ }
+
+ @Override
+ public boolean remove(WrappedKey> key) {
+ return container.remove(key.getNamespacedKey());
+ }
+
+ @Override
+ public Set implements PersistentDataType {
+
+ private final WrapType type;
+
+ public SimpleBukkitType1_19_R2(WrapType type) {
+ this.type = type;
+ }
+
+ @Override
+ public Class getPrimitiveType() {
+ return type.getPrimitiveWrapped();
+ }
+
+ @Override
+ public P toPrimitive(C complex, PersistentDataAdapterContext context) {
+ return type.wrapToPrimitive(complex, new SyntaxContext1_19_R2(context));
+ }
+
+ @Override
+ public C fromPrimitive(P primitive, PersistentDataAdapterContext context) {
+ return type.wrapToComplex(primitive, new SyntaxContext1_19_R2(context));
+ }
+
+}
\ No newline at end of file
diff --git a/vcompat-1_19_R2/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R2/data/SyntaxContainer1_19_R2.java b/vcompat-1_19_R2/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R2/data/SyntaxContainer1_19_R2.java
new file mode 100644
index 0000000..946ab82
--- /dev/null
+++ b/vcompat-1_19_R2/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R2/data/SyntaxContainer1_19_R2.java
@@ -0,0 +1,191 @@
+package net.sourcewriters.minecraft.vcompat.provider.impl.v1_19_R2.data;
+
+import java.util.Set;
+import java.util.stream.Collectors;
+
+import org.bukkit.persistence.PersistentDataContainer;
+
+import net.sourcewriters.minecraft.vcompat.VersionCompatProvider;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataAdapterContext;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataAdapterRegistry;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataContainer;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataType;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrapType;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrappedContainer;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrappedKey;
+import net.sourcewriters.minecraft.vcompat.provider.data.wrap.SyntaxKey;
+import net.sourcewriters.minecraft.vcompat.shaded.syntaxapi.utils.key.IKey;
+
+public final class SyntaxContainer1_19_R2 extends WrappedContainer implements IDataContainer {
+
+ private final PersistentDataContainer container;
+
+ public SyntaxContainer1_19_R2(PersistentDataContainer container) {
+ this.container = container;
+ }
+
+ @Override
+ public PersistentDataContainer getHandle() {
+ return container;
+ }
+
+ @Override
+ public IDataContainer getAsSyntaxContainer() {
+ return new SyntaxContainer1_19_R2(container);
+ }
+
+ @Override
+ public IDataAdapterRegistry> getRegistry() {
+ return VersionCompatProvider.get().getControl().getDataProvider().getRegistry();
+ }
+
+ /*
+ *
+ */
+
+ @Override
+ public boolean has(IKey key) {
+ throw new UnsupportedOperationException("Can't be used with PersistentDataContainer of Bukkit");
+ }
+
+ @Override
+ public boolean has(String key, IDataType, ?> type) {
+ return has(syntaxKey(key), type);
+ }
+
+ @Override
+ public boolean has(IKey key, IDataType, ?> type) {
+ return has(new SyntaxKey(key), WrappedType1_19_R2.wrap(type));
+ }
+
+ @Override
+ public boolean has(String key, WrapType type) {
+ return has(wrappedKey(key), type);
+ }
+
+ @Override
+ public boolean has(WrappedKey> key, WrapType type) {
+ return container.has(BukkitKey1_19_R2.asBukkit(key), new SimpleBukkitType1_19_R2<>(type));
+ }
+
+ @Override
+ public Object get(WrappedKey> key) {
+ throw new UnsupportedOperationException("Can't be used with PersistentDataContainer of Bukkit");
+ }
+
+ @Override
+ public C get(String key, WrapType type) {
+ return get(wrappedKey(key), type);
+ }
+
+ @Override
+ public C get(WrappedKey> key, WrapType type) {
+ return container.get(BukkitKey1_19_R2.asBukkit(key), new SimpleBukkitType1_19_R2<>(type));
+ }
+
+ @Override
+ public void set(String key, B value, WrapType, B> type) {
+ set(wrappedKey(key), value, type);
+ }
+
+ @Override
+ public void set(WrappedKey> key, B value, WrapType, B> type) {
+ container.set(BukkitKey1_19_R2.asBukkit(key), new SimpleBukkitType1_19_R2<>(type), value);
+ }
+
+ @Override
+ public boolean remove(WrappedKey> key) {
+ container.remove(BukkitKey1_19_R2.asBukkit(key));
+ return true; // Will always return true as we don't know if it contained it
+ }
+
+ @Override
+ public Set WrapType wrap(IDataType dataType) {
+ return new BukkitType1_19_R3<>(dataType);
+ }
+
+}
\ No newline at end of file
diff --git a/vcompat-1_19_R3/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R3/EntityProvider1_19_R3.java b/vcompat-1_19_R3/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R3/EntityProvider1_19_R3.java
new file mode 100644
index 0000000..085fcd9
--- /dev/null
+++ b/vcompat-1_19_R3/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R3/EntityProvider1_19_R3.java
@@ -0,0 +1,47 @@
+package net.sourcewriters.minecraft.vcompat.provider.impl.v1_19_R3;
+
+import java.util.EnumMap;
+import java.util.function.Function;
+
+import org.bukkit.craftbukkit.v1_19_R3.CraftWorld;
+
+import net.minecraft.world.level.Level;
+import net.sourcewriters.minecraft.vcompat.provider.EntityProvider;
+import net.sourcewriters.minecraft.vcompat.provider.entity.NmsEntity;
+import net.sourcewriters.minecraft.vcompat.provider.entity.NmsEntityType;
+import net.sourcewriters.minecraft.vcompat.provider.impl.v1_19_R3.utils.EntityConstructors1_19_R3;
+
+public class EntityProvider1_19_R3 extends EntityProvider boolean has(String key, WrapType type) {
+ return has(wrappedKey(key), type);
+ }
+
+ @Override
+ public boolean has(WrappedKey> key, WrapType type) {
+ return container.has(key.getNamespacedKey(), type.syntaxType());
+ }
+
+ @Override
+ public Object get(String key) {
+ return get(wrappedKey(key));
+ }
+
+ @Override
+ public Object get(WrappedKey> key) {
+ return container.get(key.getNamespacedKey());
+ }
+
+ @Override
+ public C get(String key, WrapType type) {
+ return get(wrappedKey(key), type);
+ }
+
+ @Override
+ public C get(WrappedKey> key, WrapType type) {
+ return container.get(key.getNamespacedKey(), type.syntaxType());
+ }
+
+ @Override
+ public void set(String key, B value, WrapType, B> type) {
+ set(wrappedKey(key), value, type);
+ }
+
+ @Override
+ public void set(WrappedKey> key, B value, WrapType, B> type) {
+ container.set(key.getNamespacedKey(), value, type.syntaxType());
+ }
+
+ @Override
+ public boolean remove(String key) {
+ return false;
+ }
+
+ @Override
+ public boolean remove(WrappedKey> key) {
+ return container.remove(key.getNamespacedKey());
+ }
+
+ @Override
+ public Set implements PersistentDataType {
+
+ private final WrapType type;
+
+ public SimpleBukkitType1_19_R3(WrapType type) {
+ this.type = type;
+ }
+
+ @Override
+ public Class getPrimitiveType() {
+ return type.getPrimitiveWrapped();
+ }
+
+ @Override
+ public P toPrimitive(C complex, PersistentDataAdapterContext context) {
+ return type.wrapToPrimitive(complex, new SyntaxContext1_19_R3(context));
+ }
+
+ @Override
+ public C fromPrimitive(P primitive, PersistentDataAdapterContext context) {
+ return type.wrapToComplex(primitive, new SyntaxContext1_19_R3(context));
+ }
+
+}
\ No newline at end of file
diff --git a/vcompat-1_19_R3/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R3/data/SyntaxContainer1_19_R3.java b/vcompat-1_19_R3/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R3/data/SyntaxContainer1_19_R3.java
new file mode 100644
index 0000000..aa46c90
--- /dev/null
+++ b/vcompat-1_19_R3/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_19_R3/data/SyntaxContainer1_19_R3.java
@@ -0,0 +1,191 @@
+package net.sourcewriters.minecraft.vcompat.provider.impl.v1_19_R3.data;
+
+import java.util.Set;
+import java.util.stream.Collectors;
+
+import org.bukkit.persistence.PersistentDataContainer;
+
+import net.sourcewriters.minecraft.vcompat.VersionCompatProvider;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataAdapterContext;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataAdapterRegistry;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataContainer;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataType;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrapType;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrappedContainer;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrappedKey;
+import net.sourcewriters.minecraft.vcompat.provider.data.wrap.SyntaxKey;
+import net.sourcewriters.minecraft.vcompat.shaded.syntaxapi.utils.key.IKey;
+
+public final class SyntaxContainer1_19_R3 extends WrappedContainer implements IDataContainer {
+
+ private final PersistentDataContainer container;
+
+ public SyntaxContainer1_19_R3(PersistentDataContainer container) {
+ this.container = container;
+ }
+
+ @Override
+ public PersistentDataContainer getHandle() {
+ return container;
+ }
+
+ @Override
+ public IDataContainer getAsSyntaxContainer() {
+ return new SyntaxContainer1_19_R3(container);
+ }
+
+ @Override
+ public IDataAdapterRegistry> getRegistry() {
+ return VersionCompatProvider.get().getControl().getDataProvider().getRegistry();
+ }
+
+ /*
+ *
+ */
+
+ @Override
+ public boolean has(IKey key) {
+ throw new UnsupportedOperationException("Can't be used with PersistentDataContainer of Bukkit");
+ }
+
+ @Override
+ public boolean has(String key, IDataType, ?> type) {
+ return has(syntaxKey(key), type);
+ }
+
+ @Override
+ public boolean has(IKey key, IDataType, ?> type) {
+ return has(new SyntaxKey(key), WrappedType1_19_R3.wrap(type));
+ }
+
+ @Override
+ public boolean has(String key, WrapType type) {
+ return has(wrappedKey(key), type);
+ }
+
+ @Override
+ public boolean has(WrappedKey> key, WrapType type) {
+ return container.has(BukkitKey1_19_R3.asBukkit(key), new SimpleBukkitType1_19_R3<>(type));
+ }
+
+ @Override
+ public Object get(WrappedKey> key) {
+ throw new UnsupportedOperationException("Can't be used with PersistentDataContainer of Bukkit");
+ }
+
+ @Override
+ public C get(String key, WrapType type) {
+ return get(wrappedKey(key), type);
+ }
+
+ @Override
+ public C get(WrappedKey> key, WrapType type) {
+ return container.get(BukkitKey1_19_R3.asBukkit(key), new SimpleBukkitType1_19_R3<>(type));
+ }
+
+ @Override
+ public void set(String key, B value, WrapType, B> type) {
+ set(wrappedKey(key), value, type);
+ }
+
+ @Override
+ public void set(WrappedKey> key, B value, WrapType, B> type) {
+ container.set(BukkitKey1_19_R3.asBukkit(key), new SimpleBukkitType1_19_R3<>(type), value);
+ }
+
+ @Override
+ public boolean remove(WrappedKey> key) {
+ container.remove(BukkitKey1_19_R3.asBukkit(key));
+ return true; // Will always return true as we don't know if it contained it
+ }
+
+ @Override
+ public Set WrapType wrap(IDataType dataType) {
+ return new BukkitType1_20_R1<>(dataType);
+ }
+
+}
\ No newline at end of file
diff --git a/vcompat-1_20_R1/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_20_R1/EntityProvider1_20_R1.java b/vcompat-1_20_R1/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_20_R1/EntityProvider1_20_R1.java
new file mode 100644
index 0000000..a99d63a
--- /dev/null
+++ b/vcompat-1_20_R1/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_20_R1/EntityProvider1_20_R1.java
@@ -0,0 +1,47 @@
+package net.sourcewriters.minecraft.vcompat.provider.impl.v1_20_R1;
+
+import java.util.EnumMap;
+import java.util.function.Function;
+
+import org.bukkit.craftbukkit.v1_20_R1.CraftWorld;
+
+import net.minecraft.world.level.Level;
+import net.sourcewriters.minecraft.vcompat.provider.EntityProvider;
+import net.sourcewriters.minecraft.vcompat.provider.entity.NmsEntity;
+import net.sourcewriters.minecraft.vcompat.provider.entity.NmsEntityType;
+import net.sourcewriters.minecraft.vcompat.provider.impl.v1_20_R1.utils.EntityConstructors1_20_R1;
+
+public class EntityProvider1_20_R1 extends EntityProvider boolean has(String key, WrapType type) {
+ return has(wrappedKey(key), type);
+ }
+
+ @Override
+ public boolean has(WrappedKey> key, WrapType type) {
+ return container.has(key.getNamespacedKey(), type.syntaxType());
+ }
+
+ @Override
+ public Object get(String key) {
+ return get(wrappedKey(key));
+ }
+
+ @Override
+ public Object get(WrappedKey> key) {
+ return container.get(key.getNamespacedKey());
+ }
+
+ @Override
+ public C get(String key, WrapType type) {
+ return get(wrappedKey(key), type);
+ }
+
+ @Override
+ public C get(WrappedKey> key, WrapType type) {
+ return container.get(key.getNamespacedKey(), type.syntaxType());
+ }
+
+ @Override
+ public void set(String key, B value, WrapType, B> type) {
+ set(wrappedKey(key), value, type);
+ }
+
+ @Override
+ public void set(WrappedKey> key, B value, WrapType, B> type) {
+ container.set(key.getNamespacedKey(), value, type.syntaxType());
+ }
+
+ @Override
+ public boolean remove(String key) {
+ return false;
+ }
+
+ @Override
+ public boolean remove(WrappedKey> key) {
+ return container.remove(key.getNamespacedKey());
+ }
+
+ @Override
+ public Set implements PersistentDataType {
+
+ private final WrapType type;
+
+ public SimpleBukkitType1_20_R1(WrapType type) {
+ this.type = type;
+ }
+
+ @Override
+ public Class getPrimitiveType() {
+ return type.getPrimitiveWrapped();
+ }
+
+ @Override
+ public P toPrimitive(C complex, PersistentDataAdapterContext context) {
+ return type.wrapToPrimitive(complex, new SyntaxContext1_20_R1(context));
+ }
+
+ @Override
+ public C fromPrimitive(P primitive, PersistentDataAdapterContext context) {
+ return type.wrapToComplex(primitive, new SyntaxContext1_20_R1(context));
+ }
+
+}
\ No newline at end of file
diff --git a/vcompat-1_20_R1/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_20_R1/data/SyntaxContainer1_20_R1.java b/vcompat-1_20_R1/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_20_R1/data/SyntaxContainer1_20_R1.java
new file mode 100644
index 0000000..cb843ab
--- /dev/null
+++ b/vcompat-1_20_R1/src/main/java/net/sourcewriters/minecraft/vcompat/provider/impl/v1_20_R1/data/SyntaxContainer1_20_R1.java
@@ -0,0 +1,191 @@
+package net.sourcewriters.minecraft.vcompat.provider.impl.v1_20_R1.data;
+
+import java.util.Set;
+import java.util.stream.Collectors;
+
+import org.bukkit.persistence.PersistentDataContainer;
+
+import net.sourcewriters.minecraft.vcompat.VersionCompatProvider;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataAdapterContext;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataAdapterRegistry;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataContainer;
+import net.sourcewriters.minecraft.vcompat.data.api.IDataType;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrapType;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrappedContainer;
+import net.sourcewriters.minecraft.vcompat.provider.data.WrappedKey;
+import net.sourcewriters.minecraft.vcompat.provider.data.wrap.SyntaxKey;
+import net.sourcewriters.minecraft.vcompat.shaded.syntaxapi.utils.key.IKey;
+
+public final class SyntaxContainer1_20_R1 extends WrappedContainer implements IDataContainer {
+
+ private final PersistentDataContainer container;
+
+ public SyntaxContainer1_20_R1(PersistentDataContainer container) {
+ this.container = container;
+ }
+
+ @Override
+ public PersistentDataContainer getHandle() {
+ return container;
+ }
+
+ @Override
+ public IDataContainer getAsSyntaxContainer() {
+ return new SyntaxContainer1_20_R1(container);
+ }
+
+ @Override
+ public IDataAdapterRegistry> getRegistry() {
+ return VersionCompatProvider.get().getControl().getDataProvider().getRegistry();
+ }
+
+ /*
+ *
+ */
+
+ @Override
+ public boolean has(IKey key) {
+ throw new UnsupportedOperationException("Can't be used with PersistentDataContainer of Bukkit");
+ }
+
+ @Override
+ public boolean has(String key, IDataType, ?> type) {
+ return has(syntaxKey(key), type);
+ }
+
+ @Override
+ public boolean has(IKey key, IDataType, ?> type) {
+ return has(new SyntaxKey(key), WrappedType1_20_R1.wrap(type));
+ }
+
+ @Override
+ public