Class BnCPouringRecipeDeserializer

java.lang.Object
com.petrolpark.compat.brewinandchewin.BnCPouringRecipeDeserializer
All Implemented Interfaces:
CompatRecipeDeserializer<com.simibubi.create.content.fluids.transfer.FillingRecipe>

public class BnCPouringRecipeDeserializer extends Object implements CompatRecipeDeserializer<com.simibubi.create.content.fluids.transfer.FillingRecipe>
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final com.mojang.serialization.Decoder<Optional<com.simibubi.create.content.fluids.transfer.FillingRecipe>>
     
    static final net.minecraft.resources.ResourceLocation
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.resources.ResourceLocation
    createId(net.minecraft.resources.ResourceLocation baseId)
     
    com.mojang.serialization.Decoder<Optional<com.simibubi.create.content.fluids.transfer.FillingRecipe>>
    Decoder that should emulate the Codec used by the other mod's Recipe Serializer.
    net.minecraft.resources.ResourceLocation
    The ID of the other mod's Recipe Serializer that this CompatRecipeDeserializer should emulate.
    boolean
    shouldDeserialize(com.google.gson.JsonElement element, net.minecraft.resources.ResourceLocation id)
     

    Methods inherited from class java.lang.Object

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

    • SERIALIZER_ID

      public static final net.minecraft.resources.ResourceLocation SERIALIZER_ID
    • DECODER

      public static final com.mojang.serialization.Decoder<Optional<com.simibubi.create.content.fluids.transfer.FillingRecipe>> DECODER
  • Constructor Details

    • BnCPouringRecipeDeserializer

      public BnCPouringRecipeDeserializer()
  • Method Details

    • serializerId

      public net.minecraft.resources.ResourceLocation serializerId()
      Description copied from interface: CompatRecipeDeserializer
      The ID of the other mod's Recipe Serializer that this CompatRecipeDeserializer should emulate.
      Specified by:
      serializerId in interface CompatRecipeDeserializer<com.simibubi.create.content.fluids.transfer.FillingRecipe>
    • decoder

      public com.mojang.serialization.Decoder<Optional<com.simibubi.create.content.fluids.transfer.FillingRecipe>> decoder()
      Description copied from interface: CompatRecipeDeserializer
      Decoder that should emulate the Codec used by the other mod's Recipe Serializer. This Decoder should return a DataResult.error(java.util.function.Supplier<java.lang.String>, R) if there is a formatting issue with the Recipe, but a DataResult.success(R) containing an empty Optional if there is nothing unexpected with the JSON but it cannot be converted (for example, if the other mod's Recipe may optionally include Fluids but your Recipe cannot).
      Specified by:
      decoder in interface CompatRecipeDeserializer<com.simibubi.create.content.fluids.transfer.FillingRecipe>
    • shouldDeserialize

      public boolean shouldDeserialize(com.google.gson.JsonElement element, net.minecraft.resources.ResourceLocation id)
      Specified by:
      shouldDeserialize in interface CompatRecipeDeserializer<com.simibubi.create.content.fluids.transfer.FillingRecipe>
    • createId

      public net.minecraft.resources.ResourceLocation createId(net.minecraft.resources.ResourceLocation baseId)
      Specified by:
      createId in interface CompatRecipeDeserializer<com.simibubi.create.content.fluids.transfer.FillingRecipe>