Add deprecation documentation to Archive.iterator

See gh-16655
This commit is contained in:
Phillip Webb
2019-12-19 16:52:47 -08:00
parent 1e117c704b
commit 93d9147864
2 changed files with 14 additions and 6 deletions

View File

@@ -79,6 +79,13 @@ public interface Archive extends Iterable<Archive.Entry>, AutoCloseable {
throw new IllegalStateException("Unexpected call to getNestedArchives(filter)");
}
/**
* Return a new iterator for the archive entries.
* @see java.lang.Iterable#iterator()
* @deprecated since 2.3.0 in favor of using
* {@link org.springframework.boot.loader.jar.JarFile} to access entries and
* {@link #getNestedArchives(EntryFilter, EntryFilter)} for accessing nested archives.
*/
@Deprecated
@Override
Iterator<Entry> iterator();