org.eclipse.wst.jsdt.core.dom

## Interface IPackageBinding

All Superinterfaces:
  IBinding

    public interface IPackageBinding
    extends IBinding

A package binding represents a named or unnamed package.

This interface is not intended to be implemented by clients.

Note: This Class only applies to ECMAScript 4 which is not yet supported

Provisional API: This class/interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.

### Field Summary

### Fields inherited from interface org.eclipse.wst.jsdt.core.dom.IBinding

`METHOD, PACKAGE, TYPE, VARIABLE`

### Method Summary

All Methods Instance Methods Abstract Methods
`java.lang.String` `getName()` Returns the name of the package represented by this binding.
`java.lang.String[]` `getNameComponents()` Returns the list of name component making up the name of the package represented by this binding.
`boolean` `isUnnamed()` Returns whether this package is an unnamed package.

### Methods inherited from interface org.eclipse.wst.jsdt.core.dom.IBinding

`equals, getJavaElement, getKey, getKind, getModifiers, isDeprecated, isEqualTo, isRecovered, toString`

### Method Detail

#### getName

    java.lang.String getName()

Returns the name of the package represented by this binding. For named packages, this is the fully qualified package name (using "." for separators). For unnamed packages, this is an empty string.

Specified by:
  `getName` in interface `IBinding`
Returns:
  the name of the package represented by this binding, or an empty string for an unnamed package

#### isUnnamed

    boolean isUnnamed()

Returns whether this package is an unnamed package.

Returns:
  `true` if this is an unnamed package, and `false` otherwise

#### getNameComponents

    java.lang.String[] getNameComponents()

Returns the list of name component making up the name of the package represented by this binding. For example, for the package named "com.example.tool", this method returns {"com", "example", "tool"}. Returns the empty list for unnamed packages.

Returns:
  the name of the package represented by this binding, or the empty list for unnamed packages