Class ScreenHandlerType<T extends ScreenHandler>

java.lang.Object
net.minecraft.screen.ScreenHandlerType<T>
All Implemented Interfaces:
ToggleableFeature

public class ScreenHandlerType<T extends ScreenHandler> extends Object implements ToggleableFeature
Screen handler type is used to create screen handlers on the client. It is a holder object holding a factory (usually a reference to the constructor). They are registered in the registry under Registries.SCREEN_HANDLER.

Technically speaking, screen handlers do not have to register screen handler types. However, such screen handlers are practically useless as they cannot be opened server-side using conventional methods.

See Also:
API Note:
Screen handler types should not be used to create a new screen handler on the server. See ScreenHandlerFactory for server-side creation.
Mappings:
Namespace Name
official ccj
intermediary net/minecraft/class_3917
named net/minecraft/screen/ScreenHandlerType
  • Field Details

    • GENERIC_9X1

      public static final ScreenHandlerType<GenericContainerScreenHandler> GENERIC_9X1
      Mappings:
      Namespace Name Mixin selector
      official a Lccj;a:Lccj;
      intermediary field_18664 Lnet/minecraft/class_3917;field_18664:Lnet/minecraft/class_3917;
      named GENERIC_9X1 Lnet/minecraft/screen/ScreenHandlerType;GENERIC_9X1:Lnet/minecraft/screen/ScreenHandlerType;
    • GENERIC_9X2

      public static final ScreenHandlerType<GenericContainerScreenHandler> GENERIC_9X2
      Mappings:
      Namespace Name Mixin selector
      official b Lccj;b:Lccj;
      intermediary field_18665 Lnet/minecraft/class_3917;field_18665:Lnet/minecraft/class_3917;
      named GENERIC_9X2 Lnet/minecraft/screen/ScreenHandlerType;GENERIC_9X2:Lnet/minecraft/screen/ScreenHandlerType;
    • GENERIC_9X3

      public static final ScreenHandlerType<GenericContainerScreenHandler> GENERIC_9X3
      Mappings:
      Namespace Name Mixin selector
      official c Lccj;c:Lccj;
      intermediary field_17326 Lnet/minecraft/class_3917;field_17326:Lnet/minecraft/class_3917;
      named GENERIC_9X3 Lnet/minecraft/screen/ScreenHandlerType;GENERIC_9X3:Lnet/minecraft/screen/ScreenHandlerType;
    • GENERIC_9X4

      public static final ScreenHandlerType<GenericContainerScreenHandler> GENERIC_9X4
      Mappings:
      Namespace Name Mixin selector
      official d Lccj;d:Lccj;
      intermediary field_18666 Lnet/minecraft/class_3917;field_18666:Lnet/minecraft/class_3917;
      named GENERIC_9X4 Lnet/minecraft/screen/ScreenHandlerType;GENERIC_9X4:Lnet/minecraft/screen/ScreenHandlerType;
    • GENERIC_9X5

      public static final ScreenHandlerType<GenericContainerScreenHandler> GENERIC_9X5
      Mappings:
      Namespace Name Mixin selector
      official e Lccj;e:Lccj;
      intermediary field_18667 Lnet/minecraft/class_3917;field_18667:Lnet/minecraft/class_3917;
      named GENERIC_9X5 Lnet/minecraft/screen/ScreenHandlerType;GENERIC_9X5:Lnet/minecraft/screen/ScreenHandlerType;
    • GENERIC_9X6

      public static final ScreenHandlerType<GenericContainerScreenHandler> GENERIC_9X6
      Mappings:
      Namespace Name Mixin selector
      official f Lccj;f:Lccj;
      intermediary field_17327 Lnet/minecraft/class_3917;field_17327:Lnet/minecraft/class_3917;
      named GENERIC_9X6 Lnet/minecraft/screen/ScreenHandlerType;GENERIC_9X6:Lnet/minecraft/screen/ScreenHandlerType;
    • GENERIC_3X3

      public static final ScreenHandlerType<Generic3x3ContainerScreenHandler> GENERIC_3X3
      Mappings:
      Namespace Name Mixin selector
      official g Lccj;g:Lccj;
      intermediary field_17328 Lnet/minecraft/class_3917;field_17328:Lnet/minecraft/class_3917;
      named GENERIC_3X3 Lnet/minecraft/screen/ScreenHandlerType;GENERIC_3X3:Lnet/minecraft/screen/ScreenHandlerType;
    • ANVIL

      public static final ScreenHandlerType<AnvilScreenHandler> ANVIL
      Mappings:
      Namespace Name Mixin selector
      official h Lccj;h:Lccj;
      intermediary field_17329 Lnet/minecraft/class_3917;field_17329:Lnet/minecraft/class_3917;
      named ANVIL Lnet/minecraft/screen/ScreenHandlerType;ANVIL:Lnet/minecraft/screen/ScreenHandlerType;
    • BEACON

      public static final ScreenHandlerType<BeaconScreenHandler> BEACON
      Mappings:
      Namespace Name Mixin selector
      official i Lccj;i:Lccj;
      intermediary field_17330 Lnet/minecraft/class_3917;field_17330:Lnet/minecraft/class_3917;
      named BEACON Lnet/minecraft/screen/ScreenHandlerType;BEACON:Lnet/minecraft/screen/ScreenHandlerType;
    • BLAST_FURNACE

      public static final ScreenHandlerType<BlastFurnaceScreenHandler> BLAST_FURNACE
      Mappings:
      Namespace Name Mixin selector
      official j Lccj;j:Lccj;
      intermediary field_17331 Lnet/minecraft/class_3917;field_17331:Lnet/minecraft/class_3917;
      named BLAST_FURNACE Lnet/minecraft/screen/ScreenHandlerType;BLAST_FURNACE:Lnet/minecraft/screen/ScreenHandlerType;
    • BREWING_STAND

      public static final ScreenHandlerType<BrewingStandScreenHandler> BREWING_STAND
      Mappings:
      Namespace Name Mixin selector
      official k Lccj;k:Lccj;
      intermediary field_17332 Lnet/minecraft/class_3917;field_17332:Lnet/minecraft/class_3917;
      named BREWING_STAND Lnet/minecraft/screen/ScreenHandlerType;BREWING_STAND:Lnet/minecraft/screen/ScreenHandlerType;
    • CRAFTING

      public static final ScreenHandlerType<CraftingScreenHandler> CRAFTING
      Mappings:
      Namespace Name Mixin selector
      official l Lccj;l:Lccj;
      intermediary field_17333 Lnet/minecraft/class_3917;field_17333:Lnet/minecraft/class_3917;
      named CRAFTING Lnet/minecraft/screen/ScreenHandlerType;CRAFTING:Lnet/minecraft/screen/ScreenHandlerType;
    • ENCHANTMENT

      public static final ScreenHandlerType<EnchantmentScreenHandler> ENCHANTMENT
      Mappings:
      Namespace Name Mixin selector
      official m Lccj;m:Lccj;
      intermediary field_17334 Lnet/minecraft/class_3917;field_17334:Lnet/minecraft/class_3917;
      named ENCHANTMENT Lnet/minecraft/screen/ScreenHandlerType;ENCHANTMENT:Lnet/minecraft/screen/ScreenHandlerType;
    • FURNACE

      public static final ScreenHandlerType<FurnaceScreenHandler> FURNACE
      Mappings:
      Namespace Name Mixin selector
      official n Lccj;n:Lccj;
      intermediary field_17335 Lnet/minecraft/class_3917;field_17335:Lnet/minecraft/class_3917;
      named FURNACE Lnet/minecraft/screen/ScreenHandlerType;FURNACE:Lnet/minecraft/screen/ScreenHandlerType;
    • GRINDSTONE

      public static final ScreenHandlerType<GrindstoneScreenHandler> GRINDSTONE
      Mappings:
      Namespace Name Mixin selector
      official o Lccj;o:Lccj;
      intermediary field_17336 Lnet/minecraft/class_3917;field_17336:Lnet/minecraft/class_3917;
      named GRINDSTONE Lnet/minecraft/screen/ScreenHandlerType;GRINDSTONE:Lnet/minecraft/screen/ScreenHandlerType;
    • HOPPER

      public static final ScreenHandlerType<HopperScreenHandler> HOPPER
      Mappings:
      Namespace Name Mixin selector
      official p Lccj;p:Lccj;
      intermediary field_17337 Lnet/minecraft/class_3917;field_17337:Lnet/minecraft/class_3917;
      named HOPPER Lnet/minecraft/screen/ScreenHandlerType;HOPPER:Lnet/minecraft/screen/ScreenHandlerType;
    • LECTERN

      public static final ScreenHandlerType<LecternScreenHandler> LECTERN
      Mappings:
      Namespace Name Mixin selector
      official q Lccj;q:Lccj;
      intermediary field_17338 Lnet/minecraft/class_3917;field_17338:Lnet/minecraft/class_3917;
      named LECTERN Lnet/minecraft/screen/ScreenHandlerType;LECTERN:Lnet/minecraft/screen/ScreenHandlerType;
    • LOOM

      public static final ScreenHandlerType<LoomScreenHandler> LOOM
      Mappings:
      Namespace Name Mixin selector
      official r Lccj;r:Lccj;
      intermediary field_17339 Lnet/minecraft/class_3917;field_17339:Lnet/minecraft/class_3917;
      named LOOM Lnet/minecraft/screen/ScreenHandlerType;LOOM:Lnet/minecraft/screen/ScreenHandlerType;
    • MERCHANT

      public static final ScreenHandlerType<MerchantScreenHandler> MERCHANT
      Mappings:
      Namespace Name Mixin selector
      official s Lccj;s:Lccj;
      intermediary field_17340 Lnet/minecraft/class_3917;field_17340:Lnet/minecraft/class_3917;
      named MERCHANT Lnet/minecraft/screen/ScreenHandlerType;MERCHANT:Lnet/minecraft/screen/ScreenHandlerType;
    • SHULKER_BOX

      public static final ScreenHandlerType<ShulkerBoxScreenHandler> SHULKER_BOX
      Mappings:
      Namespace Name Mixin selector
      official t Lccj;t:Lccj;
      intermediary field_17341 Lnet/minecraft/class_3917;field_17341:Lnet/minecraft/class_3917;
      named SHULKER_BOX Lnet/minecraft/screen/ScreenHandlerType;SHULKER_BOX:Lnet/minecraft/screen/ScreenHandlerType;
    • LEGACY_SMITHING

      public static final ScreenHandlerType<LegacySmithingScreenHandler> LEGACY_SMITHING
      Mappings:
      Namespace Name Mixin selector
      official u Lccj;u:Lccj;
      intermediary field_41922 Lnet/minecraft/class_3917;field_41922:Lnet/minecraft/class_3917;
      named LEGACY_SMITHING Lnet/minecraft/screen/ScreenHandlerType;LEGACY_SMITHING:Lnet/minecraft/screen/ScreenHandlerType;
    • SMITHING

      public static final ScreenHandlerType<SmithingScreenHandler> SMITHING
      Mappings:
      Namespace Name Mixin selector
      official v Lccj;v:Lccj;
      intermediary field_22484 Lnet/minecraft/class_3917;field_22484:Lnet/minecraft/class_3917;
      named SMITHING Lnet/minecraft/screen/ScreenHandlerType;SMITHING:Lnet/minecraft/screen/ScreenHandlerType;
    • SMOKER

      public static final ScreenHandlerType<SmokerScreenHandler> SMOKER
      Mappings:
      Namespace Name Mixin selector
      official w Lccj;w:Lccj;
      intermediary field_17342 Lnet/minecraft/class_3917;field_17342:Lnet/minecraft/class_3917;
      named SMOKER Lnet/minecraft/screen/ScreenHandlerType;SMOKER:Lnet/minecraft/screen/ScreenHandlerType;
    • CARTOGRAPHY_TABLE

      public static final ScreenHandlerType<CartographyTableScreenHandler> CARTOGRAPHY_TABLE
      Mappings:
      Namespace Name Mixin selector
      official x Lccj;x:Lccj;
      intermediary field_17343 Lnet/minecraft/class_3917;field_17343:Lnet/minecraft/class_3917;
      named CARTOGRAPHY_TABLE Lnet/minecraft/screen/ScreenHandlerType;CARTOGRAPHY_TABLE:Lnet/minecraft/screen/ScreenHandlerType;
    • STONECUTTER

      public static final ScreenHandlerType<StonecutterScreenHandler> STONECUTTER
      Mappings:
      Namespace Name Mixin selector
      official y Lccj;y:Lccj;
      intermediary field_17625 Lnet/minecraft/class_3917;field_17625:Lnet/minecraft/class_3917;
      named STONECUTTER Lnet/minecraft/screen/ScreenHandlerType;STONECUTTER:Lnet/minecraft/screen/ScreenHandlerType;
    • requiredFeatures

      private final FeatureSet requiredFeatures
      Mappings:
      Namespace Name Mixin selector
      official z Lccj;z:Lcau;
      intermediary field_41923 Lnet/minecraft/class_3917;field_41923:Lnet/minecraft/class_7699;
      named requiredFeatures Lnet/minecraft/screen/ScreenHandlerType;requiredFeatures:Lnet/minecraft/resource/featuretoggle/FeatureSet;
    • factory

      private final ScreenHandlerType.Factory<T extends ScreenHandler> factory
      Mappings:
      Namespace Name Mixin selector
      official A Lccj;A:Lccj$a;
      intermediary field_17344 Lnet/minecraft/class_3917;field_17344:Lnet/minecraft/class_3917$class_3918;
      named factory Lnet/minecraft/screen/ScreenHandlerType;factory:Lnet/minecraft/screen/ScreenHandlerType$Factory;
  • Constructor Details

    • ScreenHandlerType

      private ScreenHandlerType(ScreenHandlerType.Factory<T> factory, FeatureSet requiredFeatures)
      Mappings:
      Namespace Name Mixin selector
      official <init> Lccj;<init>(Lccj$a;Lcau;)V
      intermediary <init> Lnet/minecraft/class_3917;<init>(Lnet/minecraft/class_3917$class_3918;Lnet/minecraft/class_7699;)V
      named <init> Lnet/minecraft/screen/ScreenHandlerType;<init>(Lnet/minecraft/screen/ScreenHandlerType$Factory;Lnet/minecraft/resource/featuretoggle/FeatureSet;)V
  • Method Details

    • register

      private static <T extends ScreenHandler> ScreenHandlerType<T> register(String id, ScreenHandlerType.Factory<T> factory)
      Mappings:
      Namespace Name Mixin selector
      official a Lccj;a(Ljava/lang/String;Lccj$a;)Lccj;
      intermediary method_17435 Lnet/minecraft/class_3917;method_17435(Ljava/lang/String;Lnet/minecraft/class_3917$class_3918;)Lnet/minecraft/class_3917;
      named register Lnet/minecraft/screen/ScreenHandlerType;register(Ljava/lang/String;Lnet/minecraft/screen/ScreenHandlerType$Factory;)Lnet/minecraft/screen/ScreenHandlerType;
    • register

      private static <T extends ScreenHandler> ScreenHandlerType<T> register(String id, ScreenHandlerType.Factory<T> factory, FeatureFlag[] requiredFeatures)
      Mappings:
      Namespace Name Mixin selector
      official a Lccj;a(Ljava/lang/String;Lccj$a;[Lcas;)Lccj;
      intermediary method_48387 Lnet/minecraft/class_3917;method_48387(Ljava/lang/String;Lnet/minecraft/class_3917$class_3918;[Lnet/minecraft/class_7696;)Lnet/minecraft/class_3917;
      named register Lnet/minecraft/screen/ScreenHandlerType;register(Ljava/lang/String;Lnet/minecraft/screen/ScreenHandlerType$Factory;[Lnet/minecraft/resource/featuretoggle/FeatureFlag;)Lnet/minecraft/screen/ScreenHandlerType;
    • create

      public T create(int syncId, PlayerInventory playerInventory)
      Mappings:
      Namespace Name Mixin selector
      official a Lccj;a(ILbyl;)Lcbd;
      intermediary method_17434 Lnet/minecraft/class_3917;method_17434(ILnet/minecraft/class_1661;)Lnet/minecraft/class_1703;
      named create Lnet/minecraft/screen/ScreenHandlerType;create(ILnet/minecraft/entity/player/PlayerInventory;)Lnet/minecraft/screen/ScreenHandler;
    • getRequiredFeatures

      public FeatureSet getRequiredFeatures()
      Specified by:
      getRequiredFeatures in interface ToggleableFeature
      Mappings:
      Namespace Name Mixin selector
      official m Lcar;m()Lcau;
      intermediary method_45322 Lnet/minecraft/class_7695;method_45322()Lnet/minecraft/class_7699;
      named getRequiredFeatures Lnet/minecraft/resource/featuretoggle/ToggleableFeature;getRequiredFeatures()Lnet/minecraft/resource/featuretoggle/FeatureSet;