Skip to content

Commit

Permalink
Stop warning that Caffeine requires Java 8.
Browse files Browse the repository at this point in the history
So does Guava :)

Also, restore balance to the force after cl/696692285 by using `@link` instead of `@code` (or eliminating `#` while keeping `@code`) in various places.

RELNOTES=n/a
PiperOrigin-RevId: 698378812
  • Loading branch information
cpovirk authored and Google Java Core Libraries committed Nov 20, 2024
1 parent 9166ed0 commit 3853b98
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public class PeekingIteratorTest extends TestCase {
*
* <p>This IteratorTester makes copies of the master so that it can later verify that {@link
* PeekingIterator#remove()} removes the same elements as the reference's iterator {@code
* #remove()}.
* remove()}.
*/
private static class PeekingIteratorTester<T extends @Nullable Object> extends IteratorTester<T> {
private Iterable<T> master;
Expand Down
10 changes: 5 additions & 5 deletions android/guava/src/com/google/common/cache/CacheBuilder.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@
*
* <p>The successor to Guava's caching API is <a
* href="https://github.com/ben-manes/caffeine/wiki">Caffeine</a>. Its API is designed to make it a
* nearly drop-in replacement. It requires Java 8+, and is not available for Android or GWT/J2CL,
* and may have <a href="https://github.com/ben-manes/caffeine/wiki/Guava">different (usually
* better) behavior</a> when multiple threads attempt concurrent mutations. Its equivalent to {@code
* nearly drop-in replacement. Note that it is not available for Android or GWT/J2CL and that it may
* have <a href="https://github.com/ben-manes/caffeine/wiki/Guava">different (usually better)
* behavior</a> when multiple threads attempt concurrent mutations. Its equivalent to {@code
* CacheBuilder} is its <a
* href="https://www.javadoc.io/doc/com.github.ben-manes.caffeine/caffeine/latest/com.github.benmanes.caffeine/com/github/benmanes/caffeine/cache/Caffeine.html">{@code
* Caffeine}</a> class. Caffeine offers better performance, more features (including asynchronous
Expand Down Expand Up @@ -182,10 +182,10 @@
* explanation.
*
* @param <K> the most general key type this builder will be able to create caches for. This is
* normally {@code Object} unless it is constrained by using a method like {@code
* normally {@code Object} unless it is constrained by using a method like {@link
* #removalListener}. Cache keys may not be null.
* @param <V> the most general value type this builder will be able to create caches for. This is
* normally {@code Object} unless it is constrained by using a method like {@code
* normally {@code Object} unless it is constrained by using a method like {@link
* #removalListener}. Cache values may not be null.
* @author Charles Fry
* @author Kevin Bourrillion
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public class PeekingIteratorTest extends TestCase {
*
* <p>This IteratorTester makes copies of the master so that it can later verify that {@link
* PeekingIterator#remove()} removes the same elements as the reference's iterator {@code
* #remove()}.
* remove()}.
*/
private static class PeekingIteratorTester<T extends @Nullable Object> extends IteratorTester<T> {
private Iterable<T> master;
Expand Down
10 changes: 5 additions & 5 deletions guava/src/com/google/common/cache/CacheBuilder.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@
*
* <p>The successor to Guava's caching API is <a
* href="https://github.com/ben-manes/caffeine/wiki">Caffeine</a>. Its API is designed to make it a
* nearly drop-in replacement. It requires Java 8+, and is not available for Android or GWT/J2CL,
* and may have <a href="https://github.com/ben-manes/caffeine/wiki/Guava">different (usually
* better) behavior</a> when multiple threads attempt concurrent mutations. Its equivalent to {@code
* nearly drop-in replacement. Note that it is not available for Android or GWT/J2CL and that it may
* have <a href="https://github.com/ben-manes/caffeine/wiki/Guava">different (usually better)
* behavior</a> when multiple threads attempt concurrent mutations. Its equivalent to {@code
* CacheBuilder} is its <a
* href="https://www.javadoc.io/doc/com.github.ben-manes.caffeine/caffeine/latest/com.github.benmanes.caffeine/com/github/benmanes/caffeine/cache/Caffeine.html">{@code
* Caffeine}</a> class. Caffeine offers better performance, more features (including asynchronous
Expand Down Expand Up @@ -182,10 +182,10 @@
* explanation.
*
* @param <K> the most general key type this builder will be able to create caches for. This is
* normally {@code Object} unless it is constrained by using a method like {@code
* normally {@code Object} unless it is constrained by using a method like {@link
* #removalListener}. Cache keys may not be null.
* @param <V> the most general value type this builder will be able to create caches for. This is
* normally {@code Object} unless it is constrained by using a method like {@code
* normally {@code Object} unless it is constrained by using a method like {@link
* #removalListener}. Cache values may not be null.
* @author Charles Fry
* @author Kevin Bourrillion
Expand Down

0 comments on commit 3853b98

Please sign in to comment.