Class RegistryTypeAdapter<T>

java.lang.Object
com.google.gson.TypeAdapter<T>
net.darkhax.msmlegacy.config.adapters.RegistryTypeAdapter<T>

public class RegistryTypeAdapter<T> extends com.google.gson.TypeAdapter<T>
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static RegistryTypeAdapter<net.minecraft.world.effect.MobEffect>
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    RegistryTypeAdapter(net.minecraft.core.Registry<T> registry)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    read(com.google.gson.stream.JsonReader in)
     
    void
    write(com.google.gson.stream.JsonWriter out, T value)
     

    Methods inherited from class com.google.gson.TypeAdapter

    fromJson, fromJson, fromJsonTree, nullSafe, toJson, toJson, toJsonTree

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • MOB_EFFECT

      public static RegistryTypeAdapter<net.minecraft.world.effect.MobEffect> MOB_EFFECT
  • Constructor Details

    • RegistryTypeAdapter

      public RegistryTypeAdapter(net.minecraft.core.Registry<T> registry)
  • Method Details

    • write

      public void write(com.google.gson.stream.JsonWriter out, T value) throws IOException
      Specified by:
      write in class com.google.gson.TypeAdapter<T>
      Throws:
      IOException
    • read

      public T read(com.google.gson.stream.JsonReader in) throws IOException
      Specified by:
      read in class com.google.gson.TypeAdapter<T>
      Throws:
      IOException