public class Parser extends Object implements Closeable
Modifier and Type | Class and Description |
---|---|
static class |
Parser.Result |
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_WAIT_SYSPROP |
Constructor and Description |
---|
Parser(ParsingContext context) |
Modifier and Type | Method and Description |
---|---|
Exception[] |
awaitTermination() |
Exception[] |
awaitTermination(int timeOut,
TimeUnit unit) |
void |
close() |
ParsingContext |
getContext()
Returns the context this parser instance was initialized with during
the call to
Parser(ParsingContext) |
Future<Parser.Result> |
parse(ArchiveAdapter source,
Runnable doneHook)
Parse the archive adapter entries and run the runnable hook on completion.
|
void |
parse(File source,
Runnable doneHook) |
public static final String DEFAULT_WAIT_SYSPROP
public Parser(ParsingContext context)
public Exception[] awaitTermination() throws InterruptedException
InterruptedException
public Exception[] awaitTermination(int timeOut, TimeUnit unit) throws InterruptedException
InterruptedException
public void close()
close
in interface Closeable
close
in interface AutoCloseable
public void parse(File source, Runnable doneHook) throws IOException
IOException
public Future<Parser.Result> parse(ArchiveAdapter source, Runnable doneHook) throws IOException
source
- the archive adapter to parsedoneHook
- the runnable hook to run after completionIOException
- thrown by the source archive adapter when accessing entriespublic ParsingContext getContext()
Parser(ParsingContext)
Copyright © 2009–2023 Oracle Corporation. All rights reserved.