Add file tools for v1 xml stores

This commit is contained in:
René Pfeuffer
2019-06-21 14:35:57 +02:00
parent 9172892097
commit 75cd5165e3
4 changed files with 217 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
package sonia.scm.update;
import java.io.IOException;
import java.nio.file.Path;
public interface PropertyFileAccess {
Target renameGlobalConfigurationFrom(String oldName);
interface Target {
void to(String newName) throws IOException;
}
StoreFileTools forStoreName(String name);
interface StoreFileTools {
void forStoreFiles(FileConsumer storeFileConsumer) throws IOException;
void moveAsRepositoryStore(Path storeFile, String repositoryId) throws IOException;
}
public interface FileConsumer {
void accept(Path file, String repositoryId) throws IOException;
}
}