mirror of https://github.com/apache/lucene.git
LUCENE-7373: remove deprecated API
This commit is contained in:
parent
df9efb8b6d
commit
3125fccd8d
|
@ -90,24 +90,6 @@ public abstract class Directory implements Closeable {
|
|||
*/
|
||||
public abstract void sync(Collection<String> names) throws IOException;
|
||||
|
||||
/**
|
||||
* Renames {@code source} to {@code dest} as an atomic operation,
|
||||
* where {@code dest} does not yet exist in the directory.
|
||||
* <p>
|
||||
* Notes: This method is used by IndexWriter to publish commits.
|
||||
* It is ok if this operation is not truly atomic, for example
|
||||
* both {@code source} and {@code dest} can be visible temporarily.
|
||||
* It is just important that the contents of {@code dest} appear
|
||||
* atomically, or an exception is thrown.
|
||||
*
|
||||
* @deprecated Use {@link #rename} and {@link #syncMetaData} instead.
|
||||
*/
|
||||
@Deprecated
|
||||
public final void renameFile(String source, String dest) throws IOException {
|
||||
rename(source, dest);
|
||||
syncMetaData();
|
||||
}
|
||||
|
||||
/**
|
||||
* Renames {@code source} to {@code dest} as an atomic operation,
|
||||
* where {@code dest} does not yet exist in the directory.
|
||||
|
|
|
@ -39,7 +39,6 @@ public class TestFilterDirectory extends BaseDirectoryTestCase {
|
|||
Set<Method> exclude = new HashSet<>();
|
||||
exclude.add(Directory.class.getMethod("copyFrom", Directory.class, String.class, String.class, IOContext.class));
|
||||
exclude.add(Directory.class.getMethod("openChecksumInput", String.class, IOContext.class));
|
||||
exclude.add(Directory.class.getMethod("renameFile", String.class, String.class));
|
||||
for (Method m : FilterDirectory.class.getMethods()) {
|
||||
if (m.getDeclaringClass() == Directory.class) {
|
||||
assertTrue("method " + m.getName() + " not overridden!", exclude.contains(m));
|
||||
|
|
Loading…
Reference in New Issue