org.eclipse.jdt.internal.core
Class JarEntryResource

java.lang.Object
  extended by org.eclipse.core.runtime.PlatformObject
      extended by org.eclipse.jdt.internal.core.JarEntryResource
All Implemented Interfaces:
IStorage, org.eclipse.core.runtime.IAdaptable, IJarEntryResource
Direct Known Subclasses:
JarEntryDirectory, JarEntryFile

public abstract class JarEntryResource
extends org.eclipse.core.runtime.PlatformObject
implements IJarEntryResource


Constructor Summary
JarEntryResource(java.lang.String simpleName)
           
 
Method Summary
abstract  JarEntryResource clone(java.lang.Object newParent)
           
 boolean equals(java.lang.Object obj)
           
 org.eclipse.core.runtime.IPath getFullPath()
          Returns the full, absolute path of this jar entry resource relative to the archive this jar entry belongs to.
 java.lang.String getName()
          Returns the name of this storage.
 IPackageFragmentRoot getPackageFragmentRoot()
          Returns the package fragment root this jar entry resource belongs to.
 java.lang.Object getParent()
          Returns the parent of this jar entry resource.
 int hashCode()
           
 boolean isReadOnly()
          Returns whether this storage is read-only.
 void setParent(java.lang.Object parent)
           
 
Methods inherited from class org.eclipse.core.runtime.PlatformObject
getAdapter
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.jdt.core.IJarEntryResource
getChildren, isFile
 
Methods inherited from interface org.eclipse.core.resources.IStorage
getContents
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 

Constructor Detail

JarEntryResource

public JarEntryResource(java.lang.String simpleName)
Method Detail

clone

public abstract JarEntryResource clone(java.lang.Object newParent)

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

getFullPath

public org.eclipse.core.runtime.IPath getFullPath()
Description copied from interface: IJarEntryResource
Returns the full, absolute path of this jar entry resource relative to the archive this jar entry belongs to.

A jar entry resource's full path indicates the route from the root of the archive to the jar entry resource. Within an archive, there is exactly one such path for any given jar entry resource.

The returned path is absolute (i.e. it starts with a separator) and it never has a trailing separator.

Specified by:
getFullPath in interface IStorage
Specified by:
getFullPath in interface IJarEntryResource
Returns:
the absolute path of this jar entry resource

getName

public java.lang.String getName()
Description copied from interface: IStorage
Returns the name of this storage. The name of a storage is synonymous with the last segment of its full path though if the storage does not have a path, it may still have a name.

Specified by:
getName in interface IStorage
Returns:
the name of the data represented by this storage, or null if this storage has no name
See Also:
IStorage.getFullPath()

getParent

public java.lang.Object getParent()
Description copied from interface: IJarEntryResource
Returns the parent of this jar entry resource. This is either an IJarEntryResource, an IPackageFragment or an IPackageFragmentRoot.

Specified by:
getParent in interface IJarEntryResource
Returns:
the parent of this jar entry resource

getPackageFragmentRoot

public IPackageFragmentRoot getPackageFragmentRoot()
Description copied from interface: IJarEntryResource
Returns the package fragment root this jar entry resource belongs to.

Specified by:
getPackageFragmentRoot in interface IJarEntryResource
Returns:
the package fragment root this jar entry resource belongs to.

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

isReadOnly

public boolean isReadOnly()
Description copied from interface: IStorage
Returns whether this storage is read-only.

Specified by:
isReadOnly in interface IStorage
Returns:
true if this storage is read-only

setParent

public void setParent(java.lang.Object parent)