public abstract class AbstractResourcePack extends java.lang.Object implements IResourcePack
| Modifier and Type | Field and Description |
|---|---|
java.io.File |
file |
| Constructor and Description |
|---|
AbstractResourcePack(java.io.File resourcePackFileIn) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract java.io.InputStream |
getInputStream(java.lang.String resourcePath) |
<T> T |
getMetadata(IMetadataSectionSerializer<T> deserializer) |
java.lang.String |
getName() |
protected static java.lang.String |
getRelativeString(java.io.File file1,
java.io.File file2) |
static <T> T |
getResourceMetadata(IMetadataSectionSerializer<T> deserializer,
java.io.InputStream inputStream) |
java.io.InputStream |
getResourceStream(ResourcePackType type,
ResourceLocation location) |
java.io.InputStream |
getRootResourceStream(java.lang.String fileName) |
protected void |
onIgnoreNonLowercaseNamespace(java.lang.String namespace) |
boolean |
resourceExists(ResourcePackType type,
ResourceLocation location) |
protected abstract boolean |
resourceExists(java.lang.String resourcePath) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAllResourceLocations, getResourceNamespacesisHiddenpublic AbstractResourcePack(java.io.File resourcePackFileIn)
protected static java.lang.String getRelativeString(java.io.File file1,
java.io.File file2)
public java.io.InputStream getResourceStream(ResourcePackType type, ResourceLocation location) throws java.io.IOException
getResourceStream in interface IResourcePackjava.io.IOExceptionpublic boolean resourceExists(ResourcePackType type, ResourceLocation location)
resourceExists in interface IResourcePackprotected abstract java.io.InputStream getInputStream(java.lang.String resourcePath)
throws java.io.IOException
java.io.IOExceptionpublic java.io.InputStream getRootResourceStream(java.lang.String fileName)
throws java.io.IOException
getRootResourceStream in interface IResourcePackjava.io.IOExceptionprotected abstract boolean resourceExists(java.lang.String resourcePath)
protected void onIgnoreNonLowercaseNamespace(java.lang.String namespace)
@Nullable public <T> T getMetadata(IMetadataSectionSerializer<T> deserializer) throws java.io.IOException
getMetadata in interface IResourcePackjava.io.IOException@Nullable public static <T> T getResourceMetadata(IMetadataSectionSerializer<T> deserializer, java.io.InputStream inputStream)
public java.lang.String getName()
getName in interface IResourcePack