Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| org.openide.src 1.8.22
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.openide.src
Class Import

    java.lang.Object
      org.openide.src.Import

All Implemented Interfaces:
  Serializable

    public class Import

extends Object
implements Serializable

Represents one class or package import.

See Also:
  Serialized Form

Field Summary
`static boolean` | `CLASS` A class import.
`static boolean` | `PACKAGE` A package import.

Constructor Summary
`Import(Identifier id, boolean wholePackage)` Create an import.

Method Summary
`boolean` | `equals(Object o)`
`Identifier` | `getIdentifier()` Get the name of the import.
`int` | `hashCode()`
`boolean` | `isClass()` Is this a class import?
`boolean` | `isPackage()` Is this a package import?
`String` | `toString()` Get this import as a string.

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### PACKAGE

    public static final boolean PACKAGE

  A package import.

  See Also:
    Constant Field Values

### CLASS

    public static final boolean CLASS

  A class import.

  See Also:
    Constant Field Values

Constructor Detail

### Import

    public Import(Identifier id,
                  boolean wholePackage)

  Create an import.

  Parameters:
    `id` - the name of the class or package imported
    `wholePackage` - one of `PACKAGE` or `CLASS`

Method Detail

### isPackage

    public boolean isPackage()

  Is this a package import?

  Returns:
    `true` if so

### isClass

    public boolean isClass()

  Is this a class import?

  Returns:
    `true` if so

### getIdentifier

    public Identifier getIdentifier()

  Get the name of the import.

  Returns:
    the identifier which is imported

### toString

    public String toString()

  Get this import as a string.

  Overrides:
    `toString` in class `Object`
  Returns:
    e.g. `import com.mycom.Class` or `import com.mycom.*`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `Object`
  Returns:
    the hash code for this import

### equals

    public boolean equals(Object o)

  Overrides:
    `equals` in class `Object`
  Returns:
    true if the specified object is also Import of the same class or package.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| org.openide.src 1.8.22
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Built on December 7 2006. | Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.