From ec97acb808f0685ca3e09389301bf1d3c606f607 Mon Sep 17 00:00:00 2001 From: Matthias Sohn Date: Fri, 30 Aug 2024 17:17:29 +0200 Subject: [PATCH] Remove deprecated FileSnapshot.save(long) method Change-Id: I9b77142127cc96ee6658e85a6cf0586d941c5c0c --- .../internal/storage/file/FileSnapshot.java | 23 ------------------- 1 file changed, 23 deletions(-) diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileSnapshot.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileSnapshot.java index 8701a1291b..c4fa3eeb99 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileSnapshot.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileSnapshot.java @@ -125,29 +125,6 @@ public class FileSnapshot { return fileKey == null ? MISSING_FILEKEY : fileKey; } - /** - * Record a snapshot for a file for which the last modification time is - * already known. - *

- * This method should be invoked before the file is accessed. - *

- * Note that this method cannot rely on measuring file timestamp resolution - * to avoid racy git issues caused by finite file timestamp resolution since - * it's unknown in which filesystem the file is located. Hence the worst - * case fallback for timestamp resolution is used. - * - * @param modified - * the last modification time of the file - * @return the snapshot. - * @deprecated use {@link #save(Instant)} instead. - */ - @Deprecated - public static FileSnapshot save(long modified) { - final Instant read = Instant.now(); - return new FileSnapshot(read, Instant.ofEpochMilli(modified), - UNKNOWN_SIZE, FALLBACK_TIMESTAMP_RESOLUTION, MISSING_FILEKEY); - } - /** * Record a snapshot for a file for which the last modification time is * already known. -- 2.39.5