API Overview API Index Package Overview Direct link to this page
JDK 1.6
  java.lang. Package View Source
Author(s)
Since
Version
Serial
Hierarchy
 Object
      Package
Implements
 AnnotatedElement
Subclasses
Description
public class Package
  Package objects contain version information about the implementation and specification of a Java package.
Constructors
private Package (String name, Manifest man, URL url, ClassLoader loader)
pack-private Package (String name, String spectitle, String specversion, String specvendor, String impltitle, String implversion, String implvendor, URL sealbase, ClassLoader loader)
  Construct a package instance with the specified version information.
Methods
Hide/Show inherited methods
public A getAnnotation (Class< A> annotationClass)
 
public Annotation getAnnotations () [Specified in AnnotatedElement]
 
public Annotation getDeclaredAnnotations () [Specified in AnnotatedElement]
 
public String getImplementationTitle ()
  Return the title of this package.
public String getImplementationVendor ()
  Returns the name of the organization, vendor or company that provided this implementation.
public String getImplementationVersion ()
  Return the version of this implementation.
public String getName ()
  Return the name of this package.
pack-privatestatic Package getPackage (Class c)
  Get the package for the specified class.
publicstatic Package getPackage (String name)
  Find a package by name in the callers ClassLoader instance.
publicstatic Package getPackages ()
  Get all the packages currently known for the caller's ClassLoader instance.
public String getSpecificationTitle ()
  Return the title of the specification that this package implements.
public String getSpecificationVendor ()
  Return the name of the organization, vendor, or company that owns and maintains the specification of the classes that implement this package.
public String getSpecificationVersion ()
  Returns the version number of the specification that this package implements.
pack-privatestatic Package getSystemPackage (String name)
pack-privatestatic Package getSystemPackages ()
public int hashCode ()
  Return the hash code computed from the package name.
public boolean isAnnotationPresent (Class<Annotation> annotationClass) [Specified in AnnotatedElement]
 
public boolean isCompatibleWith (String desired) throws NumberFormatException
  Compare this package's specification version with a desired version.
public boolean isSealed ()
  Returns true if this package is sealed.
public boolean isSealed (URL url)
  Returns true if this package is sealed with respect to the specified code source url.
public String toString ()
  Returns the string representation of this Package.
Fields
Hide/Show inherited fields
Nested Classes
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar