Package net.minecraft.client.resources
Class LegacyResourcePackWrapper
- java.lang.Object
-
- net.minecraft.client.resources.LegacyResourcePackWrapper
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,IResourcePack
,IForgeResourcePack
public class LegacyResourcePackWrapper extends java.lang.Object implements IResourcePack
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Map<ResourceLocation,ResourceLocation>
patches
private IResourcePack
source
static java.util.Map<ResourceLocation,ResourceLocation>
V3
-
Constructor Summary
Constructors Constructor Description LegacyResourcePackWrapper(IResourcePack p_i49785_1_, java.util.Map<ResourceLocation,ResourceLocation> p_i49785_2_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
<T> T
getMetadataSection(IMetadataSectionSerializer<T> p_195760_1_)
java.lang.String
getName()
java.util.Set<java.lang.String>
getNamespaces(ResourcePackType p_195759_1_)
java.io.InputStream
getResource(ResourcePackType p_195761_1_, ResourceLocation p_195761_2_)
java.util.Collection<ResourceLocation>
getResources(ResourcePackType p_225637_1_, java.lang.String p_225637_2_, java.lang.String p_225637_3_, int p_225637_4_, java.util.function.Predicate<java.lang.String> p_225637_5_)
java.io.InputStream
getRootResource(java.lang.String p_195763_1_)
boolean
hasResource(ResourcePackType p_195764_1_, ResourceLocation p_195764_2_)
private ResourceLocation
map(ResourceLocation p_211851_1_)
private static ResourceLocation
toMetaLocation(ResourceLocation p_211850_0_)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.minecraftforge.common.extensions.IForgeResourcePack
isHidden
-
-
-
-
Field Detail
-
source
private final IResourcePack source
-
patches
private final java.util.Map<ResourceLocation,ResourceLocation> patches
-
V3
public static final java.util.Map<ResourceLocation,ResourceLocation> V3
-
-
Constructor Detail
-
LegacyResourcePackWrapper
public LegacyResourcePackWrapper(IResourcePack p_i49785_1_, java.util.Map<ResourceLocation,ResourceLocation> p_i49785_2_)
-
-
Method Detail
-
toMetaLocation
private static ResourceLocation toMetaLocation(ResourceLocation p_211850_0_)
-
map
private ResourceLocation map(ResourceLocation p_211851_1_)
-
getRootResource
public java.io.InputStream getRootResource(java.lang.String p_195763_1_) throws java.io.IOException
- Specified by:
getRootResource
in interfaceIResourcePack
- Throws:
java.io.IOException
-
getResource
public java.io.InputStream getResource(ResourcePackType p_195761_1_, ResourceLocation p_195761_2_) throws java.io.IOException
- Specified by:
getResource
in interfaceIResourcePack
- Throws:
java.io.IOException
-
getResources
public java.util.Collection<ResourceLocation> getResources(ResourcePackType p_225637_1_, java.lang.String p_225637_2_, java.lang.String p_225637_3_, int p_225637_4_, java.util.function.Predicate<java.lang.String> p_225637_5_)
- Specified by:
getResources
in interfaceIResourcePack
-
hasResource
public boolean hasResource(ResourcePackType p_195764_1_, ResourceLocation p_195764_2_)
- Specified by:
hasResource
in interfaceIResourcePack
-
getNamespaces
public java.util.Set<java.lang.String> getNamespaces(ResourcePackType p_195759_1_)
- Specified by:
getNamespaces
in interfaceIResourcePack
-
getMetadataSection
@Nullable public <T> T getMetadataSection(IMetadataSectionSerializer<T> p_195760_1_) throws java.io.IOException
- Specified by:
getMetadataSection
in interfaceIResourcePack
- Throws:
java.io.IOException
-
getName
public java.lang.String getName()
- Specified by:
getName
in interfaceIResourcePack
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfaceIResourcePack
-
-