From 15bda7eb1af912cb9f4bb71c7d7a7e6da6d65458 Mon Sep 17 00:00:00 2001 From: Michael McCandless Date: Sun, 1 Nov 2009 10:12:11 +0000 Subject: [PATCH] allow Lock.isLocked to throw IOException git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@831662 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/org/apache/lucene/store/Lock.java | 2 +- src/java/org/apache/lucene/store/VerifyingLockFactory.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/java/org/apache/lucene/store/Lock.java b/src/java/org/apache/lucene/store/Lock.java index 3a7f08f2968..d017dc54ad3 100644 --- a/src/java/org/apache/lucene/store/Lock.java +++ b/src/java/org/apache/lucene/store/Lock.java @@ -104,7 +104,7 @@ public abstract class Lock { /** Returns true if the resource is currently locked. Note that one must * still call {@link #obtain()} before using the resource. */ - public abstract boolean isLocked(); + public abstract boolean isLocked() throws IOException; /** Utility class for executing code with exclusive access. */ diff --git a/src/java/org/apache/lucene/store/VerifyingLockFactory.java b/src/java/org/apache/lucene/store/VerifyingLockFactory.java index 6fd255567bd..9abd5631db2 100644 --- a/src/java/org/apache/lucene/store/VerifyingLockFactory.java +++ b/src/java/org/apache/lucene/store/VerifyingLockFactory.java @@ -84,7 +84,7 @@ public class VerifyingLockFactory extends LockFactory { } @Override - public synchronized boolean isLocked() { + public synchronized boolean isLocked() throws IOException { return lock.isLocked(); }