Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
b71bab28
Commit
b71bab28
authored
Jun 08, 2020
by
Phillip Webb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Document deprecations of Archive.iterator()
Closes gh-21695
parent
6547ea56
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
34 additions
and
0 deletions
+34
-0
Archive.java
...java/org/springframework/boot/loader/archive/Archive.java
+34
-0
No files found.
spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/archive/Archive.java
View file @
b71bab28
...
...
@@ -21,6 +21,10 @@ import java.net.MalformedURLException;
import
java.net.URL
;
import
java.util.Iterator
;
import
java.util.List
;
import
java.util.Objects
;
import
java.util.Spliterator
;
import
java.util.Spliterators
;
import
java.util.function.Consumer
;
import
java.util.jar.Manifest
;
import
org.springframework.boot.loader.Launcher
;
...
...
@@ -90,6 +94,36 @@ public interface Archive extends Iterable<Archive.Entry>, AutoCloseable {
@Override
Iterator
<
Entry
>
iterator
();
/**
* Performs the given action for each element of the {@code Iterable} until all
* elements have been processed or the action throws an exception.
* @see Iterable#forEach
* @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
default
void
forEach
(
Consumer
<?
super
Entry
>
action
)
{
Objects
.
requireNonNull
(
action
);
for
(
Entry
entry
:
this
)
{
action
.
accept
(
entry
);
}
}
/**
* Creates a {@link Spliterator} over the elements described by this {@code Iterable}.
* @see Iterable#spliterator
* @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
default
Spliterator
<
Entry
>
spliterator
()
{
return
Spliterators
.
spliteratorUnknownSize
(
iterator
(),
0
);
}
/**
* Return if the archive is exploded (already unpacked).
* @return if the archive is exploded
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment