Package net.minecraft.server.packs
Class CompositePackResources
java.lang.Object
net.minecraft.server.packs.CompositePackResources
- All Implemented Interfaces:
AutoCloseable
,PackResources
,IPackResourcesExtension
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.server.packs.PackResources
PackResources.ResourceOutput
-
Field Summary
FieldsFields inherited from interface net.minecraft.server.packs.PackResources
METADATA_EXTENSION, PACK_META
-
Constructor Summary
ConstructorsConstructorDescriptionCompositePackResources
(PackResources pPrimaryPackResources, List<PackResources> pPackResourcesStack) -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
<T> T
getMetadataSection
(MetadataSectionSerializer<T> pDeserializer) getNamespaces
(PackType pType) getResource
(PackType pPackType, ResourceLocation pLocation) getRootResource
(String... pElements) void
listResources
(PackType pPackType, String pNamespace, String pPath, PackResources.ResourceOutput pResourceOutput) location()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.neoforged.neoforge.common.extensions.IPackResourcesExtension
isHidden
Methods inherited from interface net.minecraft.server.packs.PackResources
knownPackInfo, packId
-
Field Details
-
-
packResourcesStack
-
-
Constructor Details
-
CompositePackResources
public CompositePackResources(PackResources pPrimaryPackResources, List<PackResources> pPackResourcesStack)
-
-
Method Details
-
getRootResource
- Specified by:
getRootResource
in interfacePackResources
-
getResource
@Nullable public IoSupplier<InputStream> getResource(PackType pPackType, ResourceLocation pLocation) - Specified by:
getResource
in interfacePackResources
-
listResources
public void listResources(PackType pPackType, String pNamespace, String pPath, PackResources.ResourceOutput pResourceOutput) - Specified by:
listResources
in interfacePackResources
-
getNamespaces
- Specified by:
getNamespaces
in interfacePackResources
-
getMetadataSection
@Nullable public <T> T getMetadataSection(MetadataSectionSerializer<T> pDeserializer) throws IOException - Specified by:
getMetadataSection
in interfacePackResources
- Throws:
IOException
-
location
- Specified by:
location
in interfacePackResources
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfacePackResources
-