Class FileHistory
- java.lang.Object
-
- jetbrains.buildServer.serverSide.util.FileHistory
-
public class FileHistory extends Object
- Author:
- Maxim.Manuylov Date: 18.01.11
-
-
Constructor Summary
Constructors Constructor Description FileHistory(String fileName, File historyStorageDir)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addInitialVersionIfNeeded(Supplier<String> initialVersionContentSupplier)
int
addVersion(String versionContent)
File
findVersionByNumber(int versionNumber)
String
getLastVersionContent()
int
getLastVersionNumber()
public for testsvoid
removeHistory()
-
-
-
Method Detail
-
getLastVersionContent
@Nullable public String getLastVersionContent() throws IOException
- Throws:
IOException
-
findVersionByNumber
@Nullable public File findVersionByNumber(int versionNumber)
-
addInitialVersionIfNeeded
public void addInitialVersionIfNeeded(@NotNull Supplier<String> initialVersionContentSupplier) throws IOException
- Throws:
IOException
-
addVersion
public int addVersion(@NotNull String versionContent) throws IOException
- Throws:
IOException
-
removeHistory
public void removeHistory()
-
getLastVersionNumber
public int getLastVersionNumber()
public for tests
-
-