diff options
Diffstat (limited to 'jimfs/src/main')
-rw-r--r-- | jimfs/src/main/java/com/google/common/jimfs/File.java | 17 | ||||
-rw-r--r-- | jimfs/src/main/java/com/google/common/jimfs/WatchServiceConfiguration.java | 5 |
2 files changed, 9 insertions, 13 deletions
diff --git a/jimfs/src/main/java/com/google/common/jimfs/File.java b/jimfs/src/main/java/com/google/common/jimfs/File.java index 99a4f59..d79b6cb 100644 --- a/jimfs/src/main/java/com/google/common/jimfs/File.java +++ b/jimfs/src/main/java/com/google/common/jimfs/File.java @@ -23,10 +23,8 @@ import com.google.common.base.MoreObjects; import com.google.common.collect.HashBasedTable; import com.google.common.collect.ImmutableSet; import com.google.common.collect.Table; - import java.io.IOException; import java.util.concurrent.locks.ReadWriteLock; - import javax.annotation.Nullable; /** @@ -176,23 +174,20 @@ public abstract class File { links--; } - /** - * Gets the creation time of the file. - */ + /** Gets the creation time of the file. */ + @SuppressWarnings("GoodTime") // should return a java.time.Instant public synchronized final long getCreationTime() { return creationTime; } - /** - * Gets the last access time of the file. - */ + /** Gets the last access time of the file. */ + @SuppressWarnings("GoodTime") // should return a java.time.Instant public synchronized final long getLastAccessTime() { return lastAccessTime; } - /** - * Gets the last modified time of the file. - */ + /** Gets the last modified time of the file. */ + @SuppressWarnings("GoodTime") // should return a java.time.Instant public synchronized final long getLastModifiedTime() { return lastModifiedTime; } diff --git a/jimfs/src/main/java/com/google/common/jimfs/WatchServiceConfiguration.java b/jimfs/src/main/java/com/google/common/jimfs/WatchServiceConfiguration.java index 4ef1a06..a93e8e3 100644 --- a/jimfs/src/main/java/com/google/common/jimfs/WatchServiceConfiguration.java +++ b/jimfs/src/main/java/com/google/common/jimfs/WatchServiceConfiguration.java @@ -38,9 +38,10 @@ public abstract class WatchServiceConfiguration { /** * Returns a configuration for a {@link WatchService} that polls watched directories for changes - * every {@code interval} of the given {@code timeUnit} (e.g. every 5 - * {@link TimeUnit#SECONDS seconds}). + * every {@code interval} of the given {@code timeUnit} (e.g. every 5 {@link TimeUnit#SECONDS + * seconds}). */ + @SuppressWarnings("GoodTime") // should accept a java.time.Duration public static WatchServiceConfiguration polling(long interval, TimeUnit timeUnit) { return new PollingConfig(interval, timeUnit); } |