Package com.android.builder.merge
Class DelegateIncrementalFileMergerOutput
java.lang.Object
com.android.builder.merge.DelegateIncrementalFileMergerOutput
- All Implemented Interfaces:
IncrementalFileMergerOutput,OpenableCloseable,Closeable,AutoCloseable
public class DelegateIncrementalFileMergerOutput
extends Object
implements IncrementalFileMergerOutput
IncrementalFileMergerOutput that delegates execution to another
IncrementalFileMergerOutput. Invoking methods on an instance will delegate execution to
the delegate.-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new output. -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidcreate(String path, List<IncrementalFileMergerInput> inputs, boolean compress) A path needs to be created.voidopen()Opens the object.voidA path needs to be removed from the output.voidupdate(String path, List<String> prevInputNames, List<IncrementalFileMergerInput> inputs, boolean compress) A path needs to be updated.
-
Constructor Details
-
DelegateIncrementalFileMergerOutput
Creates a new output.- Parameters:
delegate- the delegate
-
-
Method Details
-
open
public void open()Description copied from interface:OpenableCloseableOpens the object.- Specified by:
openin interfaceOpenableCloseable
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
remove
Description copied from interface:IncrementalFileMergerOutputA path needs to be removed from the output.- Specified by:
removein interfaceIncrementalFileMergerOutput- Parameters:
path- the OS-independent path to remove
-
create
public void create(@NonNull String path, @NonNull List<IncrementalFileMergerInput> inputs, boolean compress) Description copied from interface:IncrementalFileMergerOutputA path needs to be created.- Specified by:
createin interfaceIncrementalFileMergerOutput- Parameters:
path- the OS-independent pathinputs- the inputs where the paths exists and that should be combined to generate the output. The inputs should already be opened when passed to this method. The inputs are provided in the same order they were provided toIncrementalFileMerger.merge(List, IncrementalFileMergerOutput, IncrementalFileMergerState, Predicate)compress- whether the data will be compressed
-
update
public void update(@NonNull String path, @NonNull List<String> prevInputNames, @NonNull List<IncrementalFileMergerInput> inputs, boolean compress) Description copied from interface:IncrementalFileMergerOutputA path needs to be updated.- Specified by:
updatein interfaceIncrementalFileMergerOutput- Parameters:
path- the OS-independent pathprevInputNames- the previous inputs used to create or update the pathinputs- the inputs where the paths exists and that should be combined to generate the output. The inputs should already be opened when passed to this method. The inputs are provided in the same order they were provided toIncrementalFileMerger.merge(List, IncrementalFileMergerOutput, IncrementalFileMergerState, Predicate)compress- whether the data will be compressed
-