|
Eclipse Platform 2.1 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--org.eclipse.update.core.ContentReference
|
+--org.eclipse.update.core.JarContentReference
Local .jar file content reference.
This class may be instantiated or subclassed by clients.
ContentReference,
JarEntryContentReference| Nested Class Summary | |
static class |
JarContentReference.ContentSelector
Content selector used in .jar operations. |
| Field Summary |
| Fields inherited from class org.eclipse.update.core.ContentReference |
DEFAULT_EXECUTABLE_PERMISSION, UNKNOWN_SIZE |
| Constructor Summary | |
JarContentReference(String id,
File file)
Create jar content reference from file. |
|
JarContentReference(String id,
File file,
boolean b)
Constructor JarContentReference. |
|
JarContentReference(String id,
URL url)
Create jar content reference from URL. |
|
| Method Summary | |
protected JarFile |
asJarFile()
Returns the content reference as a jar file. |
void |
closeArchive()
Closes the jar archive corresponding to this reference. |
ContentReference |
createContentReference(String id,
File file)
A factory method to create a jar content reference. |
ContentReference[] |
peek(JarContentReference.ContentSelector selector,
InstallMonitor monitor)
Peeks into the referenced jar archive. |
ContentReference |
peek(String entryName,
JarContentReference.ContentSelector selector,
InstallMonitor monitor)
Peeks into the referenced jar archive looking for the named entry. |
static void |
shutdown()
Perform shutdown processing for jar archive handling. |
ContentReference[] |
unpack(File dir,
JarContentReference.ContentSelector selector,
InstallMonitor monitor)
Unpacks the referenced jar archive into the specified location. |
ContentReference |
unpack(File dir,
String entryName,
JarContentReference.ContentSelector selector,
InstallMonitor monitor)
Unpacks the named jar entry into the specified location. |
| Methods inherited from class org.eclipse.update.core.ContentReference |
asFile, asURL, getIdentifier, getInputSize, getInputStream, getPermission, isLocalReference, setPermission, setTempLocal, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public JarContentReference(String id,
URL url)
id - "symbolic" path identifierurl - actual referenced URL
public JarContentReference(String id,
File file)
id - "symbolic" path identifierfile - actual referenced file
public JarContentReference(String id,
File file,
boolean b)
id - file - b - | Method Detail |
public ContentReference createContentReference(String id,
File file)
createContentReference in class ContentReferenceid - "symbolic" path identifierfile - actual referenced file
protected JarFile asJarFile()
throws IOException
IOException - reference cannot be returned as jar file
public ContentReference[] unpack(File dir,
JarContentReference.ContentSelector selector,
InstallMonitor monitor)
throws IOException,
InstallAbortedException
dir - location to unpack the jar intoselector - selector, used to select entries to unpack, and to define
"symbolic" path identifiers for the entries.monitor - progress monitor
IOException
InstallAbortedException
public ContentReference unpack(File dir,
String entryName,
JarContentReference.ContentSelector selector,
InstallMonitor monitor)
throws IOException,
InstallAbortedException
dir - location to unpack the jar intoentryName - name of the jar entryselector - selector, used to define "symbolic" path identifier
for the entrymonitor - progress monitor
IOException
InstallAbortedException
public ContentReference[] peek(JarContentReference.ContentSelector selector,
InstallMonitor monitor)
throws IOException
selector - selector, used to select entries to return, and to define
"symbolic" path identifiers for the entries.monitor - progress monitor
IOException
public ContentReference peek(String entryName,
JarContentReference.ContentSelector selector,
InstallMonitor monitor)
throws IOException
entryName - name of the jar entryselector - selector, used to define "symbolic" path identifier
for the entrymonitor - progress monitor
null if the entry doesn't exist
- Throws:
IOException- Since:
- 2.0
public void closeArchive()
throws IOException
IOExceptionpublic static void shutdown()
|
Eclipse Platform 2.1 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||