Package sonia.scm.repository.api
Class ModifyCommandBuilder.WithOverwriteFlagContentLoader
java.lang.Object
sonia.scm.repository.api.ModifyCommandBuilder.WithOverwriteFlagContentLoader
- All Implemented Interfaces:
ModifyCommandBuilder.ContentLoader
- Enclosing class:
- ModifyCommandBuilder
public class ModifyCommandBuilder.WithOverwriteFlagContentLoader
extends Object
implements ModifyCommandBuilder.ContentLoader
-
Method Summary
Modifier and TypeMethodDescriptionsetOverwrite
(boolean overwrite) Set this totrue
to overwrite the file if it already exists.withData
(com.google.common.io.ByteSource data) Specify the data of the file using aByteSource
.withData
(InputStream data) Specify the data of the file using anInputStream
.
-
Method Details
-
setOverwrite
Set this totrue
to overwrite the file if it already exists. Otherwise, anAlreadyExistsException
will be thrown.- Returns:
- This loader instance.
-
withData
Description copied from interface:ModifyCommandBuilder.ContentLoader
Specify the data of the file using aByteSource
.- Specified by:
withData
in interfaceModifyCommandBuilder.ContentLoader
- Returns:
- The builder instance.
- Throws:
IOException
- If the data could not be read.
-
withData
Description copied from interface:ModifyCommandBuilder.ContentLoader
Specify the data of the file using anInputStream
.- Specified by:
withData
in interfaceModifyCommandBuilder.ContentLoader
- Returns:
- The builder instance.
- Throws:
IOException
- If the data could not be read.
-