Package net.minecraft.resources
Class FallbackResourceManager
- java.lang.Object
-
- net.minecraft.resources.FallbackResourceManager
-
- All Implemented Interfaces:
IResourceManager
public class FallbackResourceManager extends java.lang.Object implements IResourceManager
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classFallbackResourceManager.LeakComplainerInputStream-
Nested classes/interfaces inherited from interface net.minecraft.resources.IResourceManager
IResourceManager.Instance
-
-
Field Summary
Fields Modifier and Type Field Description java.util.List<IResourcePack>fallbacksprivate static org.apache.logging.log4j.LoggerLOGGERprivate java.lang.Stringnamespaceprivate ResourcePackTypetype
-
Constructor Summary
Constructors Constructor Description FallbackResourceManager(ResourcePackType p_i226096_1_, java.lang.String p_i226096_2_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(IResourcePack p_199021_1_)(package private) static ResourceLocationgetMetadataLocation(ResourceLocation p_199020_0_)java.util.Set<java.lang.String>getNamespaces()IResourcegetResource(ResourceLocation p_199002_1_)java.util.List<IResource>getResources(ResourceLocation p_199004_1_)protected java.io.InputStreamgetWrappedResource(ResourceLocation p_199019_1_, IResourcePack p_199019_2_)booleanhasResource(ResourceLocation p_219533_1_)private booleanisValidLocation(ResourceLocation p_219541_1_)java.util.stream.Stream<IResourcePack>listPacks()java.util.Collection<ResourceLocation>listResources(java.lang.String p_199003_1_, java.util.function.Predicate<java.lang.String> p_199003_2_)private voidvalidateLocation(ResourceLocation p_199022_1_)
-
-
-
Field Detail
-
LOGGER
private static final org.apache.logging.log4j.Logger LOGGER
-
fallbacks
public final java.util.List<IResourcePack> fallbacks
-
type
private final ResourcePackType type
-
namespace
private final java.lang.String namespace
-
-
Constructor Detail
-
FallbackResourceManager
public FallbackResourceManager(ResourcePackType p_i226096_1_, java.lang.String p_i226096_2_)
-
-
Method Detail
-
add
public void add(IResourcePack p_199021_1_)
-
getNamespaces
public java.util.Set<java.lang.String> getNamespaces()
- Specified by:
getNamespacesin interfaceIResourceManager
-
getResource
public IResource getResource(ResourceLocation p_199002_1_) throws java.io.IOException
- Specified by:
getResourcein interfaceIResourceManager- Throws:
java.io.IOException
-
hasResource
public boolean hasResource(ResourceLocation p_219533_1_)
- Specified by:
hasResourcein interfaceIResourceManager
-
getWrappedResource
protected java.io.InputStream getWrappedResource(ResourceLocation p_199019_1_, IResourcePack p_199019_2_) throws java.io.IOException
- Throws:
java.io.IOException
-
validateLocation
private void validateLocation(ResourceLocation p_199022_1_) throws java.io.IOException
- Throws:
java.io.IOException
-
isValidLocation
private boolean isValidLocation(ResourceLocation p_219541_1_)
-
getResources
public java.util.List<IResource> getResources(ResourceLocation p_199004_1_) throws java.io.IOException
- Specified by:
getResourcesin interfaceIResourceManager- Throws:
java.io.IOException
-
listResources
public java.util.Collection<ResourceLocation> listResources(java.lang.String p_199003_1_, java.util.function.Predicate<java.lang.String> p_199003_2_)
- Specified by:
listResourcesin interfaceIResourceManager
-
listPacks
public java.util.stream.Stream<IResourcePack> listPacks()
- Specified by:
listPacksin interfaceIResourceManager
-
getMetadataLocation
static ResourceLocation getMetadataLocation(ResourceLocation p_199020_0_)
-
-