MCPcopy Create free account
hub / github.com/VolmitSoftware/Adapt / hasName

Method hasName

src/main/java/com/volmit/adapt/util/Items.java:107–109  ·  view source on GitHub ↗

Does the item have a custom name @param is the item @return true if it has a name

(ItemStack is)

Source from the content-addressed store, hash-verified

105 * @return true if it has a name
106 */
107 public static boolean hasName(ItemStack is) {
108 return hasMeta(is) && is.getItemMeta().hasDisplayName();
109 }
110
111 /**
112 * Does the item have any lore?

Callers

nothing calls this directly

Calls 4

hasMetaMethod · 0.95
getItemMetaMethod · 0.80
getDisplayNameMethod · 0.65
equalsMethod · 0.45

Tested by

no test coverage detected