Klasse ExternalPackageFragmentRoot

Alle implementierten Schnittstellen:
IBufferChangedListener, IJavaElement, IOpenable, IPackageFragmentRoot, IParent, org.eclipse.core.runtime.IAdaptable

public class ExternalPackageFragmentRoot extends PackageFragmentRoot
A package fragment root that corresponds to an external class folder.

NOTE: An external package fragment root never has an associated resource.

Siehe auch:
  • Felddetails

    • externalPath

      protected final org.eclipse.core.runtime.IPath externalPath
      The path to the external folder (an OS path)
  • Konstruktordetails

    • ExternalPackageFragmentRoot

      protected ExternalPackageFragmentRoot(org.eclipse.core.runtime.IPath externalPath, JavaProject project)
      Constructs a package fragment root which is the root of the Java package directory hierarchy based on an external folder that is not contained in a IJavaProject and does not have an associated IResource.
    • ExternalPackageFragmentRoot

      protected ExternalPackageFragmentRoot(org.eclipse.core.resources.IResource linkedFolder, org.eclipse.core.runtime.IPath externalPath, JavaProject project)
  • Methodendetails

    • determineKind

      protected int determineKind(org.eclipse.core.resources.IResource underlyingResource)
      An external class folder is always K_BINARY.
      Setzt außer Kraft:
      determineKind in Klasse PackageFragmentRoot
    • equals

      public boolean equals(Object o)
      Returns true if this handle represents the same external folder as the given handle.
      Setzt außer Kraft:
      equals in Klasse PackageFragmentRoot
      Siehe auch:
    • getElementName

      public String getElementName()
      Beschreibung aus Schnittstelle kopiert: IJavaElement
      Returns the name of this element. This is a handle-only method.
      Angegeben von:
      getElementName in Schnittstelle IJavaElement
      Setzt außer Kraft:
      getElementName in Klasse PackageFragmentRoot
      Gibt zurück:
      the element name
      Siehe auch:
      • IAdaptable
    • getKind

      public int getKind()
      Beschreibung aus Schnittstelle kopiert: IPackageFragmentRoot
      Returns this package fragment root's kind encoded as an integer. A package fragment root can contain source files (i.e. files with one of the Java-like extensions, or .class files, but not both. If the underlying folder or archive contains other kinds of files, they are ignored. In particular, .class files are ignored under a source package fragment root, and source files are ignored under a binary package fragment root.
      Angegeben von:
      getKind in Schnittstelle IPackageFragmentRoot
      Setzt außer Kraft:
      getKind in Klasse PackageFragmentRoot
      Gibt zurück:
      this package fragment root's kind encoded as an integer
      Siehe auch:
    • getPath

      public org.eclipse.core.runtime.IPath getPath()
      Beschreibung aus Schnittstelle kopiert: IJavaElement
      Returns the path to the innermost resource enclosing this element. If this element is not included in an external library, the path returned is the full, absolute path to the underlying resource, relative to the workbench. If this element is included in an external library, the path returned is the absolute path to the archive or to the folder in the file system. This is a handle-only method.
      Angegeben von:
      getPath in Schnittstelle IJavaElement
      Setzt außer Kraft:
      getPath in Klasse PackageFragmentRoot
      Gibt zurück:
      the path to the innermost resource enclosing this element
      Siehe auch:
    • getUnderlyingResource

      public org.eclipse.core.resources.IResource getUnderlyingResource() throws JavaModelException
      Beschreibung aus Schnittstelle kopiert: IJavaElement
      Returns the smallest underlying resource that contains this element, or null if this element is not contained in a resource.
      Angegeben von:
      getUnderlyingResource in Schnittstelle IJavaElement
      Setzt außer Kraft:
      getUnderlyingResource in Klasse PackageFragmentRoot
      Gibt zurück:
      the underlying resource, or null if none
      Löst aus:
      JavaModelException - if this element does not exist or if an exception occurs while accessing its underlying resource
      Siehe auch:
    • hashCode

      public int hashCode()
      Beschreibung aus Klasse kopiert: JavaElement
      Returns the hash code for this Java element. By default, the hash code for an element is a combination of its name and parent's hash code. Elements with other requirements must override this method.
      Setzt außer Kraft:
      hashCode in Klasse PackageFragmentRoot
    • isExternal

      public boolean isExternal()
      Beschreibung aus Schnittstelle kopiert: IPackageFragmentRoot
      Returns whether this package fragment root is external to the workbench (that is, a local file), and has no underlying resource.

      This is a handle-only method.

      Angegeben von:
      isExternal in Schnittstelle IPackageFragmentRoot
      Setzt außer Kraft:
      isExternal in Klasse PackageFragmentRoot
      Gibt zurück:
      true if this package fragment root is external to the workbench (that is, a local file), and has no underlying resource, false otherwise
      Siehe auch:
    • resource

      public org.eclipse.core.resources.IResource resource(PackageFragmentRoot root)
      Setzt außer Kraft:
      resource in Klasse PackageFragmentRoot
    • resourceExists

      protected boolean resourceExists(org.eclipse.core.resources.IResource underlyingResource)
      Beschreibung aus Klasse kopiert: Openable
      Returns whether the corresponding resource or associated file exists
      Setzt außer Kraft:
      resourceExists in Klasse Openable
    • toStringAncestors

      protected void toStringAncestors(StringBuffer buffer)
      Beschreibung aus Klasse kopiert: JavaElement
      Debugging purposes
      Setzt außer Kraft:
      toStringAncestors in Klasse JavaElement