Skip to content

Commit 8079a29

Browse files
cpovirkGoogle Java Core Libraries
authored andcommitted
Remove @Beta from Streams methods mapWithIndex and findLast.
RELNOTES=`collect`: Removed `@Beta` from `Streams` methods `mapWithIndex` and `findLast`. PiperOrigin-RevId: 419831941
1 parent 3a5ef50 commit 8079a29

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

guava/src/com/google/common/collect/Streams.java

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,6 @@ private static class TemporaryPair<A extends @Nullable Object, B extends @Nullab
425425
* <p>The order of the resulting stream is defined if and only if the order of the original stream
426426
* was defined.
427427
*/
428-
@Beta
429428
public static <T extends @Nullable Object, R extends @Nullable Object> Stream<R> mapWithIndex(
430429
Stream<T> stream, FunctionWithIndex<? super T, ? extends R> function) {
431430
checkNotNull(stream);
@@ -509,7 +508,6 @@ Splitr createSplit(Spliterator<T> from, long i) {
509508
* <p>The order of the resulting stream is defined if and only if the order of the original stream
510509
* was defined.
511510
*/
512-
@Beta
513511
public static <R extends @Nullable Object> Stream<R> mapWithIndex(
514512
IntStream stream, IntFunctionWithIndex<R> function) {
515513
checkNotNull(stream);
@@ -589,7 +587,6 @@ Splitr createSplit(Spliterator.OfInt from, long i) {
589587
* <p>The order of the resulting stream is defined if and only if the order of the original stream
590588
* was defined.
591589
*/
592-
@Beta
593590
public static <R extends @Nullable Object> Stream<R> mapWithIndex(
594591
LongStream stream, LongFunctionWithIndex<R> function) {
595592
checkNotNull(stream);
@@ -669,7 +666,6 @@ Splitr createSplit(Spliterator.OfLong from, long i) {
669666
* <p>The order of the resulting stream is defined if and only if the order of the original stream
670667
* was defined.
671668
*/
672-
@Beta
673669
public static <R extends @Nullable Object> Stream<R> mapWithIndex(
674670
DoubleStream stream, DoubleFunctionWithIndex<R> function) {
675671
checkNotNull(stream);
@@ -735,7 +731,6 @@ Splitr createSplit(Spliterator.OfDouble from, long i) {
735731
*
736732
* @since 21.0
737733
*/
738-
@Beta
739734
public interface FunctionWithIndex<T extends @Nullable Object, R extends @Nullable Object> {
740735
/** Applies this function to the given argument and its index within a stream. */
741736
@ParametricNullness
@@ -791,7 +786,6 @@ public int characteristics() {
791786
*
792787
* @since 21.0
793788
*/
794-
@Beta
795789
public interface IntFunctionWithIndex<R extends @Nullable Object> {
796790
/** Applies this function to the given argument and its index within a stream. */
797791
@ParametricNullness
@@ -806,7 +800,6 @@ public interface IntFunctionWithIndex<R extends @Nullable Object> {
806800
*
807801
* @since 21.0
808802
*/
809-
@Beta
810803
public interface LongFunctionWithIndex<R extends @Nullable Object> {
811804
/** Applies this function to the given argument and its index within a stream. */
812805
@ParametricNullness
@@ -821,7 +814,6 @@ public interface LongFunctionWithIndex<R extends @Nullable Object> {
821814
*
822815
* @since 21.0
823816
*/
824-
@Beta
825817
public interface DoubleFunctionWithIndex<R extends @Nullable Object> {
826818
/** Applies this function to the given argument and its index within a stream. */
827819
@ParametricNullness
@@ -853,7 +845,6 @@ public interface DoubleFunctionWithIndex<R extends @Nullable Object> {
853845
* split has a last element of null, so throw NPE" from "the final split was empty, so look for an
854846
* element in the prior one.")
855847
*/
856-
@Beta
857848
public static <T> java.util.Optional<T> findLast(Stream<T> stream) {
858849
class OptionalState {
859850
boolean set = false;
@@ -932,7 +923,6 @@ T get() {
932923
* @see IntStream#findFirst()
933924
* @throws NullPointerException if the last element of the stream is null
934925
*/
935-
@Beta
936926
public static OptionalInt findLast(IntStream stream) {
937927
// findLast(Stream) does some allocation, so we might as well box some more
938928
java.util.Optional<Integer> boxedLast = findLast(stream.boxed());
@@ -951,7 +941,6 @@ public static OptionalInt findLast(IntStream stream) {
951941
* @see LongStream#findFirst()
952942
* @throws NullPointerException if the last element of the stream is null
953943
*/
954-
@Beta
955944
public static OptionalLong findLast(LongStream stream) {
956945
// findLast(Stream) does some allocation, so we might as well box some more
957946
java.util.Optional<Long> boxedLast = findLast(stream.boxed());
@@ -970,7 +959,6 @@ public static OptionalLong findLast(LongStream stream) {
970959
* @see DoubleStream#findFirst()
971960
* @throws NullPointerException if the last element of the stream is null
972961
*/
973-
@Beta
974962
public static OptionalDouble findLast(DoubleStream stream) {
975963
// findLast(Stream) does some allocation, so we might as well box some more
976964
java.util.Optional<Double> boxedLast = findLast(stream.boxed());

0 commit comments

Comments
 (0)