Package net.minecraft.network
Record Class HiddenByteBuf
java.lang.Object
java.lang.Record
net.minecraft.network.HiddenByteBuf
- All Implemented Interfaces:
io.netty.util.ReferenceCounted
public record HiddenByteBuf(io.netty.buffer.ByteBuf contents)
extends Record
implements io.netty.util.ReferenceCounted
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final io.netty.buffer.ByteBuf
The field for thecontents
record component. -
Constructor Summary
ConstructorsConstructorDescriptionHiddenByteBuf
(io.netty.buffer.ByteBuf contents) Creates an instance of aHiddenByteBuf
record class. -
Method Summary
Modifier and TypeMethodDescriptionio.netty.buffer.ByteBuf
contents()
Returns the value of thecontents
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.static Object
int
refCnt()
boolean
release()
boolean
release
(int p_390522_) retain()
retain
(int p_390414_) final String
toString()
Returns a string representation of this record class.touch()
static Object
-
Field Details
-
contents
private final io.netty.buffer.ByteBuf contentsThe field for thecontents
record component.
-
-
Constructor Details
-
HiddenByteBuf
public HiddenByteBuf(io.netty.buffer.ByteBuf contents) Creates an instance of aHiddenByteBuf
record class.- Parameters:
contents
- the value for thecontents
record component
-
-
Method Details
-
pack
-
unpack
-
refCnt
public int refCnt()- Specified by:
refCnt
in interfaceio.netty.util.ReferenceCounted
-
retain
- Specified by:
retain
in interfaceio.netty.util.ReferenceCounted
-
retain
- Specified by:
retain
in interfaceio.netty.util.ReferenceCounted
-
touch
- Specified by:
touch
in interfaceio.netty.util.ReferenceCounted
-
touch
- Specified by:
touch
in interfaceio.netty.util.ReferenceCounted
-
release
public boolean release()- Specified by:
release
in interfaceio.netty.util.ReferenceCounted
-
release
public boolean release(int p_390522_) - Specified by:
release
in interfaceio.netty.util.ReferenceCounted
-
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)
. -
contents
public io.netty.buffer.ByteBuf contents()Returns the value of thecontents
record component.- Returns:
- the value of the
contents
record component
-