Interface FabricRecipeManager

All Superinterfaces:
FabricRecipeAccess

public interface FabricRecipeManager extends FabricRecipeAccess
General-purpose Fabric-provided extensions for RecipeManager class.
  • Method Summary

    Modifier and Type
    Method
    Description
    default <I extends net.minecraft.world.item.crafting.RecipeInput, T extends net.minecraft.world.item.crafting.Recipe<I>>
    Stream<net.minecraft.world.item.crafting.RecipeHolder<T>>
    getAllMatches(net.minecraft.world.item.crafting.RecipeType<T> type, I input, net.minecraft.world.level.Level level)
    Creates a stream of all recipe entries of the given type that match the given input and level.
    default <I extends net.minecraft.world.item.crafting.RecipeInput, T extends net.minecraft.world.item.crafting.Recipe<I>>
    Collection<net.minecraft.world.item.crafting.RecipeHolder<T>>
    getAllOfType(net.minecraft.world.item.crafting.RecipeType<T> type)
     

    Methods inherited from interface FabricRecipeAccess

    getSynchronizedRecipes
  • Method Details

    • getAllMatches

      default <I extends net.minecraft.world.item.crafting.RecipeInput, T extends net.minecraft.world.item.crafting.Recipe<I>> Stream<net.minecraft.world.item.crafting.RecipeHolder<T>> getAllMatches(net.minecraft.world.item.crafting.RecipeType<T> type, I input, net.minecraft.world.level.Level level)
      Creates a stream of all recipe entries of the given type that match the given input and level.

      If input.isEmpty() returns true, the returned stream will be always empty.

      Returns:
      the stream of matching recipes
    • getAllOfType

      default <I extends net.minecraft.world.item.crafting.RecipeInput, T extends net.minecraft.world.item.crafting.Recipe<I>> Collection<net.minecraft.world.item.crafting.RecipeHolder<T>> getAllOfType(net.minecraft.world.item.crafting.RecipeType<T> type)
      Returns:
      the collection of recipe entries of given type