Class AssetPackManifest

java.lang.Object
com.hypixel.hytale.protocol.packets.asseteditor.AssetPackManifest

public class AssetPackManifest extends Object
  • Field Details

    • NULLABLE_BIT_FIELD_SIZE

      public static final int NULLABLE_BIT_FIELD_SIZE
      See Also:
    • FIXED_BLOCK_SIZE

      public static final int FIXED_BLOCK_SIZE
      See Also:
    • VARIABLE_FIELD_COUNT

      public static final int VARIABLE_FIELD_COUNT
      See Also:
    • VARIABLE_BLOCK_START

      public static final int VARIABLE_BLOCK_START
      See Also:
    • MAX_SIZE

      public static final int MAX_SIZE
      See Also:
    • name

      @Nullable public String name
    • group

      @Nullable public String group
    • website

      @Nullable public String website
    • description

      @Nullable public String description
    • version

      @Nullable public String version
    • authors

      @Nullable public AuthorInfo[] authors
    • serverVersion

      @Nullable public String serverVersion
  • Constructor Details

    • AssetPackManifest

      public AssetPackManifest()
    • AssetPackManifest

      public AssetPackManifest(@Nullable String name, @Nullable String group, @Nullable String website, @Nullable String description, @Nullable String version, @Nullable AuthorInfo[] authors, @Nullable String serverVersion)
    • AssetPackManifest

      public AssetPackManifest(@Nonnull AssetPackManifest other)
  • Method Details

    • requireBounds

      public static void requireBounds(MemorySegment mem, int offset)
      Checks that the fixed block fits. The per-field getters read without their own bound check, so call this once before reading fields out of an untrusted segment.
    • getName

      @Nullable public static String getName(MemorySegment mem)
    • getName

      @Nullable public static String getName(MemorySegment mem, int offset)
    • getGroup

      @Nullable public static String getGroup(MemorySegment mem)
    • getGroup

      @Nullable public static String getGroup(MemorySegment mem, int offset)
    • getWebsite

      @Nullable public static String getWebsite(MemorySegment mem)
    • getWebsite

      @Nullable public static String getWebsite(MemorySegment mem, int offset)
    • getDescription

      @Nullable public static String getDescription(MemorySegment mem)
    • getDescription

      @Nullable public static String getDescription(MemorySegment mem, int offset)
    • getVersion

      @Nullable public static String getVersion(MemorySegment mem)
    • getVersion

      @Nullable public static String getVersion(MemorySegment mem, int offset)
    • getAuthors

      @Nullable public static AuthorInfo[] getAuthors(MemorySegment mem)
    • getAuthors

      @Nullable public static AuthorInfo[] getAuthors(MemorySegment mem, int offset)
    • getServerVersion

      @Nullable public static String getServerVersion(MemorySegment mem)
    • getServerVersion

      @Nullable public static String getServerVersion(MemorySegment mem, int offset)
    • hasName

      public static boolean hasName(MemorySegment mem, int offset)
    • hasGroup

      public static boolean hasGroup(MemorySegment mem, int offset)
    • hasWebsite

      public static boolean hasWebsite(MemorySegment mem, int offset)
    • hasDescription

      public static boolean hasDescription(MemorySegment mem, int offset)
    • hasVersion

      public static boolean hasVersion(MemorySegment mem, int offset)
    • hasAuthors

      public static boolean hasAuthors(MemorySegment mem, int offset)
    • hasServerVersion

      public static boolean hasServerVersion(MemorySegment mem, int offset)
    • toObject

      public static AssetPackManifest toObject(MemorySegment mem)
    • toObject

      public static AssetPackManifest toObject(MemorySegment mem, int offset)
    • toObject

      public static AssetPackManifest toObject(MemorySegment mem, int offset, @Nullable ReadCursor cursor)
      Decodes one AssetPackManifest and reports the end of its encoding through the cursor. The variable block is decoded in field order against a running position, and each offset slot must name that position, so the fields decoded are the bytes walked.
    • serialize

      public int serialize(@Nonnull MemorySegment mem, int offset)
    • computeSize

      public int computeSize()
    • clone

      public AssetPackManifest clone()
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object