EntityDataAccessor .java

net.minecraft.network.syncher.EntityDataAccessor (record, 26 lines): members: serializer, hashCode, equals. strings: "<entity data: ".

net.minecraft.network.syncherrecord26 linescommon539 B

API Surface (3)

boolean equals(final Object o)
int hashCode()
String toString()

String literals (1)

"<entity data: "

Code Graph: Dependencies (1)

Edges (calls / imports / inherits / references) resolved by graphify from the AST. Every chip opens the class source.

Full Source

EntityDataAccessor.java26 lines · Minecraft 26.3 · verbatim
1
package net.minecraft.network.syncher;
2
3
public record EntityDataAccessor<T>(int id, EntityDataSerializer<T> serializer) {
4
	@Override
5
	public boolean equals(final Object o) {
6
		if (this == o) {
7
			return true;
8
		} else if (o != null && this.getClass() == o.getClass()) {
9
			EntityDataAccessor<?> that = (EntityDataAccessor<?>)o;
10
			return this.id == that.id;
11
		} else {
12
			return false;
13
		}
14
	}
15
16
	@Override
17
	public int hashCode() {
18
		return this.id;
19
	}
20
21
	@Override
22
	public String toString() {
23
		return "<entity data: " + this.id + ">";
24
	}
25
}
26

Decompiled Minecraft 26.3 source of EntityDataAccessor (net/minecraft/network/syncher/EntityDataAccessor.java) with Mojang official mappings, stored verbatim on the site.