Module java.base
Package java.lang.constant

Interface PackageDesc


public sealed interfacePackageDesc
A nominal descriptor for aPackage constant.

To create aPackageDesc for a package, use theof(String) orofInternalName(String) method.

SeeJava Virtual Machine Specification:
4.4.12 The CONSTANT_Package_info Structure
Since:
21
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Compare the specified object with this descriptor for equality.
    Returns the fully qualified (slash-separated) package name in internal form of thisPackageDesc.
    defaultString
    Returns the fully qualified (dot-separated) package name of thisPackageDesc.
    of(String name)
    Returns aPackageDesc for a package, given the name of the package, such as"java.lang".
    Returns aPackageDesc for a package, given the name of the package in internal form, such as"java/lang".