public interface Renamer
extends java.io.Closeable
Renamer is used to run generic transformers on a JAR file.| Modifier and Type | Interface and Description |
|---|---|
static interface |
Renamer.Builder
A
Renamer.Builder is used to configure and construct a Renamer. |
| Modifier and Type | Method and Description |
|---|---|
static Renamer.Builder |
builder()
Creates a default instance of a
Renamer.Builder. |
void |
run(java.io.File input,
java.io.File output)
Runs the renamer and all registered transformers on the input JAR file,
and then outputs it to the output JAR file.
|
java.util.List<Transformer.Entry> |
run(java.util.List<Transformer.Entry> entries)
Runs the renamer and all registered transformers on the given input entries.
|
java.util.concurrent.CompletableFuture<java.util.List<Transformer.Entry>> |
run(java.util.List<Transformer.Entry> entries,
java.util.concurrent.ExecutorService executorService)
Same as
run(List), but ignores the configured RenamerBuilder.threads(int) and instead uses the
given executorService for scheduling asynchronous tasks. |
void run(java.io.File input,
java.io.File output)
input - the input JAR file to processoutput - the output JAR file locationjava.util.List<Transformer.Entry> run(java.util.List<Transformer.Entry> entries)
This method is guaranteed to be repeatable with multiple inputs and outputs.
java.util.concurrent.CompletableFuture<java.util.List<Transformer.Entry>> run(java.util.List<Transformer.Entry> entries, java.util.concurrent.ExecutorService executorService)
run(List), but ignores the configured RenamerBuilder.threads(int) and instead uses the
given executorService for scheduling asynchronous tasks.static Renamer.Builder builder()
Renamer.Builder.
Logs will be logged to System.out by default.
Debug logs will be swallowed by default.
Library files can be both ZIP files and directories.
The default number of threads is determined from Runtime.availableProcessors().