Class ClientboundHelloPacket

java.lang.Object
org.geysermc.mcprotocollib.protocol.packet.login.clientbound.ClientboundHelloPacket
All Implemented Interfaces:
Packet, MinecraftPacket

public class ClientboundHelloPacket extends Object implements MinecraftPacket
  • Constructor Details

    • ClientboundHelloPacket

      public ClientboundHelloPacket(io.netty.buffer.ByteBuf in)
    • ClientboundHelloPacket

      public ClientboundHelloPacket(@NonNull @NonNull String serverId, @NonNull @NonNull PublicKey publicKey, byte @NonNull [] challenge, boolean shouldAuthenticate)
  • Method Details

    • serialize

      public void serialize(io.netty.buffer.ByteBuf out)
      Specified by:
      serialize in interface MinecraftPacket
    • getServerId

      @NonNull public @NonNull String getServerId()
    • getPublicKey

      @NonNull public @NonNull PublicKey getPublicKey()
    • getChallenge

      public byte @NonNull [] getChallenge()
    • isShouldAuthenticate

      public boolean isShouldAuthenticate()
    • equals

      public boolean equals(@Nullable Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(@Nullable Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public @NonNull String toString()
      Overrides:
      toString in class Object
    • withServerId

      public @NonNull ClientboundHelloPacket withServerId(@NonNull @NonNull String serverId)
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withPublicKey

      public @NonNull ClientboundHelloPacket withPublicKey(@NonNull @NonNull PublicKey publicKey)
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withChallenge

      public @NonNull ClientboundHelloPacket withChallenge(byte @NonNull [] challenge)
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withShouldAuthenticate

      public @NonNull ClientboundHelloPacket withShouldAuthenticate(boolean shouldAuthenticate)
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).