Package net.minecraft.resources
Class ResourceLocation
java.lang.Object
net.minecraft.resources.ResourceLocation
- All Implemented Interfaces:
Comparable<ResourceLocation>
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<ResourceLocation> static final Stringstatic final com.mojang.brigadier.exceptions.SimpleCommandExceptionTypeprivate final Stringstatic final charprivate final Stringstatic final Stringstatic final StreamCodec<io.netty.buffer.ByteBuf, ResourceLocation> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static StringassertValidNamespace(String p_250769_, String p_249616_) private static StringassertValidPath(String p_251418_, String p_248828_) static ResourceLocationbySeparator(String p_135823_, char p_135824_) intintcompareTo(ResourceLocation p_135826_) private static ResourceLocationcreateUntrusted(String p_352179_, String p_352115_) booleanstatic ResourceLocationfromNamespaceAndPath(String p_350583_, String p_350305_) getPath()inthashCode()static booleanisAllowedInResourceLocation(char p_135817_) static booleanisValidNamespace(String p_135844_) static booleanisValidPath(String p_135842_) static ResourceLocationstatic ResourceLocationread(com.mojang.brigadier.StringReader p_135819_) static com.mojang.serialization.DataResult<ResourceLocation> private static StringreadGreedy(com.mojang.brigadier.StringReader p_335690_) static ResourceLocationreadNonEmpty(com.mojang.brigadier.StringReader p_336027_) toLanguageKey(String p_214297_) toLanguageKey(String p_270871_, String p_270199_) toString()static ResourceLocationstatic ResourceLocationtryBySeparator(String p_352469_, char p_352244_) static ResourceLocationstatic booleanvalidNamespaceChar(char p_135836_) static booleanvalidPathChar(char p_135829_) static ResourceLocationwithDefaultNamespace(String p_350998_) withPath(UnaryOperator<String> p_250342_) withPrefix(String p_250620_) withSuffix(String p_266769_)
-
Field Details
-
CODEC
-
STREAM_CODEC
-
ERROR_INVALID
public static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_INVALID -
NAMESPACE_SEPARATOR
public static final char NAMESPACE_SEPARATOR- See Also:
-
DEFAULT_NAMESPACE
- See Also:
-
REALMS_NAMESPACE
- See Also:
-
namespace
-
path
-
-
Constructor Details
-
ResourceLocation
-
-
Method Details
-
createUntrusted
-
fromNamespaceAndPath
-
parse
-
withDefaultNamespace
-
tryParse
-
tryBuild
-
bySeparator
-
tryBySeparator
-
read
-
getPath
-
getNamespace
-
withPath
-
withPath
-
withPrefix
-
withSuffix
-
toString
-
equals
-
hashCode
public int hashCode() -
compareTo
- Specified by:
compareToin interfaceComparable<ResourceLocation>
-
compareNamespaced
-
toDebugFileName
-
toLanguageKey
-
toShortLanguageKey
-
toLanguageKey
-
toLanguageKey
-
readGreedy
-
read
public static ResourceLocation read(com.mojang.brigadier.StringReader p_135819_) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
readNonEmpty
public static ResourceLocation readNonEmpty(com.mojang.brigadier.StringReader p_336027_) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
isAllowedInResourceLocation
public static boolean isAllowedInResourceLocation(char p_135817_) -
isValidPath
-
isValidNamespace
-
assertValidNamespace
-
validPathChar
public static boolean validPathChar(char p_135829_) -
validNamespaceChar
public static boolean validNamespaceChar(char p_135836_) -
assertValidPath
-