Class PackageUtils


  • public final class PackageUtils
    extends java.lang.Object
    Provides utility methods for package names.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int PACKAGE_NAME_SIZE  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String readPackageName​(java.nio.ByteBuffer buffer, int offset)
      Reads the package name from the buffer and repositions the buffer to point directly after the package name.
      static void writePackageName​(java.nio.ByteBuffer buffer, java.lang.String packageName)
      Writes the provided package name to the buffer in UTF-16.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • readPackageName

        public static java.lang.String readPackageName​(java.nio.ByteBuffer buffer,
                                                       int offset)
        Reads the package name from the buffer and repositions the buffer to point directly after the package name.
        Parameters:
        buffer - The buffer containing the package name.
        offset - The offset in the buffer to read from.
        Returns:
        The package name.
      • writePackageName

        public static void writePackageName​(java.nio.ByteBuffer buffer,
                                            java.lang.String packageName)
        Writes the provided package name to the buffer in UTF-16.
        Parameters:
        buffer - The buffer that will be written to.
        packageName - The package name that will be written to the buffer.