@FunctionalInterface public interface WorkingDirectoryCustomizer
addResource(Resource, String)| Modifier and Type | Method and Description |
|---|---|
static WorkingDirectoryCustomizer |
addResource(Resource resource,
String path)
Copy a resource to a target path within the working directory.
|
void |
customize(Path workingDirectory,
Version version)
Customizes the working directory.
|
static WorkingDirectoryCustomizer addResource(Resource resource, String path)
- If target file does not exist, it will be created. - If target file exists, it will be replaced.For example:
WorkingDirectoryCustomizer.addResource(new ClassPathResource("cassandra.yaml"), "conf/cassandra.yaml")
path - path (file only) within the working directory (e.g conf/cassandra.yaml)resource - the resourcevoid customize(Path workingDirectory, Version version) throws IOException
workingDirectory - a working directoryversion - a versionIOException - in the case of any I/O errorsCopyright © 2023. All rights reserved.