File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed
android/src/main/java/net/servicestack/func
client/src/main/java/net/servicestack/func Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change 9
9
import java .util .Comparator ;
10
10
import java .util .HashMap ;
11
11
import java .util .HashSet ;
12
+ import java .util .Iterator ;
12
13
import java .util .List ;
13
14
import java .util .Map ;
14
15
@@ -170,6 +171,14 @@ public static <T> void each(Iterable<T> xs, Action<T> f) {
170
171
}
171
172
}
172
173
174
+ public static <T > void forEach (T [] xs , Action <T > f ) {
175
+ each (toList (xs ), f );
176
+ }
177
+
178
+ public static <T > void forEach (Iterable <T > xs , Action <T > f ){
179
+ each (xs , f );
180
+ }
181
+
173
182
public static <T > ArrayList <T > filter (T [] xs , Predicate <T > predicate ) {
174
183
return filter (toList (xs ), predicate );
175
184
}
Original file line number Diff line number Diff line change 9
9
import java .util .Comparator ;
10
10
import java .util .HashMap ;
11
11
import java .util .HashSet ;
12
+ import java .util .Iterator ;
12
13
import java .util .List ;
13
14
import java .util .Map ;
14
15
@@ -170,6 +171,14 @@ public static <T> void each(Iterable<T> xs, Action<T> f) {
170
171
}
171
172
}
172
173
174
+ public static <T > void forEach (T [] xs , Action <T > f ) {
175
+ each (toList (xs ), f );
176
+ }
177
+
178
+ public static <T > void forEach (Iterable <T > xs , Action <T > f ){
179
+ each (xs , f );
180
+ }
181
+
173
182
public static <T > ArrayList <T > filter (T [] xs , Predicate <T > predicate ) {
174
183
return filter (toList (xs ), predicate );
175
184
}
You can’t perform that action at this time.
0 commit comments