MCPcopy Create free account
hub / github.com/DGVPSH/SlackOpen / hasField

Method hasField

src/main/java/net/minecraft/util/JsonUtils.java:52–55  ·  view source on GitHub ↗

Does the given JsonObject contain a field with the given name?

(JsonObject p_151204_0_, String p_151204_1_)

Source from the content-addressed store, hash-verified

50 * Does the given JsonObject contain a field with the given name?
51 */
52 public static boolean hasField(JsonObject p_151204_0_, String p_151204_1_)
53 {
54 return p_151204_0_ == null ? false : p_151204_0_.get(p_151204_1_) != null;
55 }
56
57 /**
58 * Gets the string value of the given JsonElement. Expects the second parameter to be the name of the element's

Callers 2

isJsonArrayMethod · 0.95
isJsonPrimitiveMethod · 0.95

Calls 1

getMethod · 0.65

Tested by

no test coverage detected