From 67ef4865308a8595f72b787ebf9ed96d144be4d1 Mon Sep 17 00:00:00 2001 From: Kfir Awad <7997354+Leo40Git@users.noreply.github.com> Date: Thu, 27 Aug 2020 11:20:47 +0300 Subject: [PATCH] Clean up javadoc on Identifier(String) constructor (#1723) * Clean up javadoc on Identifier(String) constructor This was done without Enigma! Since this is, quite literally, changing 2 COMMENT lines. * Transfer comments to method rather than parameter * Add @.throws, add javadoc for tryParse * redundancy bad --- mappings/net/minecraft/util/Identifier.mapping | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/mappings/net/minecraft/util/Identifier.mapping b/mappings/net/minecraft/util/Identifier.mapping index 368b6e7a7d..8f896b5b2f 100644 --- a/mappings/net/minecraft/util/Identifier.mapping +++ b/mappings/net/minecraft/util/Identifier.mapping @@ -5,16 +5,20 @@ CLASS net/minecraft/class_2960 net/minecraft/util/Identifier FIELD field_13355 path Ljava/lang/String; FIELD field_25139 CODEC Lcom/mojang/serialization/Codec; METHOD (Ljava/lang/String;)V + COMMENT

Takes a string of the form {@code :}, for example {@code minecraft:iron_ingot}.

+ COMMENT

The string will be split (on the {@code :}) into an identifier with the specified path and namespace.

+ COMMENT Prefer using the {@link #Identifier(java.lang.String, java.lang.String)} constructor that takes the namespace and path as individual parameters to avoid mistakes. + COMMENT @throws InvalidIdentifierException if the string cannot be parsed as an identifier. ARG 1 id - COMMENT A string of the form :, for example minecraft:iron_ingot. - COMMENT The string will be split (on the :) into an identifier with the specified path and namespace. - COMMENT Prefer using the constructor {@link net.minecraft.util.Identifier#Identifier(java.lang.String, java.lang.String)} that takes the namespace and path as individual parameters to avoid mistakes. METHOD (Ljava/lang/String;Ljava/lang/String;)V ARG 1 namespace ARG 2 path METHOD ([Ljava/lang/String;)V ARG 1 id METHOD method_12829 tryParse (Ljava/lang/String;)Lnet/minecraft/class_2960; + COMMENT

Parses a string into an {@code Identifier}.

+ COMMENT Takes a string of the form {@code :}, for example {@code minecraft:iron_ingot}. + COMMENT @return resulting identifier, or {@code null} if the string couldn't be parsed as an identifier ARG 0 id METHOD method_12830 split (Ljava/lang/String;C)[Ljava/lang/String; ARG 0 id