Record Class ResolvableProfile
java.lang.Object
java.lang.Record
net.minecraft.world.item.component.ResolvableProfile
-
Field Summary
Modifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec
<ResolvableProfile> private static final com.mojang.serialization.Codec
<ResolvableProfile> private final com.mojang.authlib.GameProfile
The field for thegameProfile
record component.The field for theid
record component.The field for thename
record component.private final com.mojang.authlib.properties.PropertyMap
The field for theproperties
record component.static final StreamCodec
<io.netty.buffer.ByteBuf, ResolvableProfile> -
Constructor Summary
ConstructorDescriptionResolvableProfile
(com.mojang.authlib.GameProfile p_332009_) ResolvableProfile
(Optional<String> p_330853_, Optional<UUID> p_332668_, com.mojang.authlib.properties.PropertyMap p_331206_) ResolvableProfile
(Optional<String> name, Optional<UUID> id, com.mojang.authlib.properties.PropertyMap properties, com.mojang.authlib.GameProfile gameProfile) Creates an instance of aResolvableProfile
record class. -
Method Summary
Modifier and TypeMethodDescriptionprivate static com.mojang.authlib.GameProfile
createProfile
(Optional<String> p_331092_, Optional<UUID> p_332678_, com.mojang.authlib.properties.PropertyMap p_331544_) final boolean
Indicates whether some other object is "equal to" this one.com.mojang.authlib.GameProfile
Returns the value of thegameProfile
record component.final int
hashCode()
Returns a hash code value for this object.id()
Returns the value of theid
record component.boolean
name()
Returns the value of thename
record component.com.mojang.authlib.properties.PropertyMap
Returns the value of theproperties
record component.resolve()
final String
toString()
Returns a string representation of this record class.
-
Field Details
-
name
The field for thename
record component. -
id
The field for theid
record component. -
properties
private final com.mojang.authlib.properties.PropertyMap propertiesThe field for theproperties
record component. -
gameProfile
private final com.mojang.authlib.GameProfile gameProfileThe field for thegameProfile
record component. -
FULL_CODEC
-
CODEC
-
STREAM_CODEC
-
-
Constructor Details
-
ResolvableProfile
-
ResolvableProfile
public ResolvableProfile(com.mojang.authlib.GameProfile p_332009_) -
ResolvableProfile
public ResolvableProfile(Optional<String> name, Optional<UUID> id, com.mojang.authlib.properties.PropertyMap properties, com.mojang.authlib.GameProfile gameProfile) Creates an instance of aResolvableProfile
record class.- Parameters:
name
- the value for thename
record componentid
- the value for theid
record componentproperties
- the value for theproperties
record componentgameProfile
- the value for thegameProfile
record component
-
-
Method Details
-
resolve
-
createProfile
-
isResolved
public boolean isResolved() -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-
id
Returns the value of theid
record component.- Returns:
- the value of the
id
record component
-
properties
public com.mojang.authlib.properties.PropertyMap properties()Returns the value of theproperties
record component.- Returns:
- the value of the
properties
record component
-
gameProfile
public com.mojang.authlib.GameProfile gameProfile()Returns the value of thegameProfile
record component.- Returns:
- the value of the
gameProfile
record component
-