CollectionsKt__IterablesKt.smali
14.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
.class Lkotlin/collections/CollectionsKt__IterablesKt;
.super Lkotlin/collections/CollectionsKt__CollectionsKt;
.source "Iterables.kt"
# annotations
.annotation runtime Lkotlin/Metadata;
bv = {
0x1,
0x0,
0x3
}
d1 = {
"\u0000:\n\u0000\n\u0002\u0010\u001c\n\u0002\u0008\u0002\n\u0002\u0018\u0002\n\u0002\u0010(\n\u0000\n\u0002\u0010\u0008\n\u0002\u0008\u0004\n\u0002\u0010\u001e\n\u0002\u0008\u0003\n\u0002\u0010 \n\u0000\n\u0002\u0010\u000b\n\u0002\u0008\u0002\n\u0002\u0018\u0002\n\u0002\u0008\u0002\u001a+\u0010\u0000\u001a\u0008\u0012\u0004\u0012\u0002H\u00020\u0001\"\u0004\u0008\u0000\u0010\u00022\u0014\u0008\u0004\u0010\u0003\u001a\u000e\u0012\n\u0012\u0008\u0012\u0004\u0012\u0002H\u00020\u00050\u0004H\u0087\u0008\u001a \u0010\u0006\u001a\u00020\u0007\"\u0004\u0008\u0000\u0010\u0002*\u0008\u0012\u0004\u0012\u0002H\u00020\u00012\u0006\u0010\u0008\u001a\u00020\u0007H\u0001\u001a\u001f\u0010\t\u001a\u0004\u0018\u00010\u0007\"\u0004\u0008\u0000\u0010\u0002*\u0008\u0012\u0004\u0012\u0002H\u00020\u0001H\u0001\u00a2\u0006\u0002\u0010\n\u001a\u001e\u0010\u000b\u001a\u0008\u0012\u0004\u0012\u0002H\u00020\u000c\"\u0004\u0008\u0000\u0010\u0002*\u0008\u0012\u0004\u0012\u0002H\u00020\u0001H\u0000\u001a,\u0010\r\u001a\u0008\u0012\u0004\u0012\u0002H\u00020\u000c\"\u0004\u0008\u0000\u0010\u0002*\u0008\u0012\u0004\u0012\u0002H\u00020\u00012\u000c\u0010\u000e\u001a\u0008\u0012\u0004\u0012\u0002H\u00020\u0001H\u0000\u001a\"\u0010\u000f\u001a\u0008\u0012\u0004\u0012\u0002H\u00020\u0010\"\u0004\u0008\u0000\u0010\u0002*\u000e\u0012\n\u0012\u0008\u0012\u0004\u0012\u0002H\u00020\u00010\u0001\u001a\u001d\u0010\u0011\u001a\u00020\u0012\"\u0004\u0008\u0000\u0010\u0002*\u0008\u0012\u0004\u0012\u0002H\u00020\u000cH\u0002\u00a2\u0006\u0002\u0008\u0013\u001a@\u0010\u0014\u001a\u001a\u0012\n\u0012\u0008\u0012\u0004\u0012\u0002H\u00020\u0010\u0012\n\u0012\u0008\u0012\u0004\u0012\u0002H\u00160\u00100\u0015\"\u0004\u0008\u0000\u0010\u0002\"\u0004\u0008\u0001\u0010\u0016*\u0014\u0012\u0010\u0012\u000e\u0012\u0004\u0012\u0002H\u0002\u0012\u0004\u0012\u0002H\u00160\u00150\u0001\u00a8\u0006\u0017"
}
d2 = {
"Iterable",
"",
"T",
"iterator",
"Lkotlin/Function0;",
"",
"collectionSizeOrDefault",
"",
"default",
"collectionSizeOrNull",
"(Ljava/lang/Iterable;)Ljava/lang/Integer;",
"convertToSetForSetOperation",
"",
"convertToSetForSetOperationWith",
"source",
"flatten",
"",
"safeToConvertToSet",
"",
"safeToConvertToSet$CollectionsKt__IterablesKt",
"unzip",
"Lkotlin/Pair;",
"R",
"kotlin-stdlib"
}
k = 0x5
mv = {
0x1,
0x1,
0xf
}
xi = 0x1
xs = "kotlin/collections/CollectionsKt"
.end annotation
# direct methods
.method public constructor <init>()V
.locals 0
invoke-direct {p0}, Lkotlin/collections/CollectionsKt__CollectionsKt;-><init>()V
return-void
.end method
.method private static final Iterable(Lkotlin/jvm/functions/Function0;)Ljava/lang/Iterable;
.locals 1
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Lkotlin/jvm/functions/Function0<",
"+",
"Ljava/util/Iterator<",
"+TT;>;>;)",
"Ljava/lang/Iterable<",
"TT;>;"
}
.end annotation
.annotation build Lkotlin/internal/InlineOnly;
.end annotation
.line 16
new-instance v0, Lkotlin/collections/CollectionsKt__IterablesKt$Iterable$1;
invoke-direct {v0, p0}, Lkotlin/collections/CollectionsKt__IterablesKt$Iterable$1;-><init>(Lkotlin/jvm/functions/Function0;)V
check-cast v0, Ljava/lang/Iterable;
return-object v0
.end method
.method public static final collectionSizeOrDefault(Ljava/lang/Iterable;I)I
.locals 1
.param p0 # Ljava/lang/Iterable;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/Iterable<",
"+TT;>;I)I"
}
.end annotation
.annotation build Lkotlin/PublishedApi;
.end annotation
const-string v0, "$this$collectionSizeOrDefault"
invoke-static {p0, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
.line 39
instance-of v0, p0, Ljava/util/Collection;
if-eqz v0, :cond_0
check-cast p0, Ljava/util/Collection;
invoke-interface {p0}, Ljava/util/Collection;->size()I
move-result p1
:cond_0
return p1
.end method
.method public static final collectionSizeOrNull(Ljava/lang/Iterable;)Ljava/lang/Integer;
.locals 1
.param p0 # Ljava/lang/Iterable;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/Iterable<",
"+TT;>;)",
"Ljava/lang/Integer;"
}
.end annotation
.annotation build Lkotlin/PublishedApi;
.end annotation
.annotation build Lorg/jetbrains/annotations/Nullable;
.end annotation
const-string v0, "$this$collectionSizeOrNull"
invoke-static {p0, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
.line 33
instance-of v0, p0, Ljava/util/Collection;
if-eqz v0, :cond_0
check-cast p0, Ljava/util/Collection;
invoke-interface {p0}, Ljava/util/Collection;->size()I
move-result p0
invoke-static {p0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object p0
goto :goto_0
:cond_0
const/4 p0, 0x0
:goto_0
return-object p0
.end method
.method public static final convertToSetForSetOperation(Ljava/lang/Iterable;)Ljava/util/Collection;
.locals 2
.param p0 # Ljava/lang/Iterable;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/Iterable<",
"+TT;>;)",
"Ljava/util/Collection<",
"TT;>;"
}
.end annotation
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
const-string v0, "$this$convertToSetForSetOperation"
invoke-static {p0, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
.line 59
instance-of v0, p0, Ljava/util/Set;
if-eqz v0, :cond_0
check-cast p0, Ljava/util/Collection;
goto :goto_0
.line 60
:cond_0
instance-of v0, p0, Ljava/util/Collection;
if-eqz v0, :cond_2
move-object v0, p0
check-cast v0, Ljava/util/Collection;
invoke-static {v0}, Lkotlin/collections/CollectionsKt__IterablesKt;->safeToConvertToSet$CollectionsKt__IterablesKt(Ljava/util/Collection;)Z
move-result v1
if-eqz v1, :cond_1
invoke-static {p0}, Lkotlin/collections/CollectionsKt;->toHashSet(Ljava/lang/Iterable;)Ljava/util/HashSet;
move-result-object p0
check-cast p0, Ljava/util/Collection;
goto :goto_0
:cond_1
move-object p0, v0
goto :goto_0
.line 61
:cond_2
invoke-static {p0}, Lkotlin/collections/CollectionsKt;->toHashSet(Ljava/lang/Iterable;)Ljava/util/HashSet;
move-result-object p0
check-cast p0, Ljava/util/Collection;
:goto_0
return-object p0
.end method
.method public static final convertToSetForSetOperationWith(Ljava/lang/Iterable;Ljava/lang/Iterable;)Ljava/util/Collection;
.locals 1
.param p0 # Ljava/lang/Iterable;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.param p1 # Ljava/lang/Iterable;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/Iterable<",
"+TT;>;",
"Ljava/lang/Iterable<",
"+TT;>;)",
"Ljava/util/Collection<",
"TT;>;"
}
.end annotation
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
const-string v0, "$this$convertToSetForSetOperationWith"
invoke-static {p0, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
const-string v0, "source"
invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
.line 47
instance-of v0, p0, Ljava/util/Set;
if-eqz v0, :cond_0
check-cast p0, Ljava/util/Collection;
goto :goto_0
.line 48
:cond_0
instance-of v0, p0, Ljava/util/Collection;
if-eqz v0, :cond_3
.line 50
instance-of v0, p1, Ljava/util/Collection;
if-eqz v0, :cond_1
check-cast p1, Ljava/util/Collection;
invoke-interface {p1}, Ljava/util/Collection;->size()I
move-result p1
const/4 v0, 0x2
if-ge p1, v0, :cond_1
check-cast p0, Ljava/util/Collection;
goto :goto_0
.line 51
:cond_1
move-object p1, p0
check-cast p1, Ljava/util/Collection;
invoke-static {p1}, Lkotlin/collections/CollectionsKt__IterablesKt;->safeToConvertToSet$CollectionsKt__IterablesKt(Ljava/util/Collection;)Z
move-result v0
if-eqz v0, :cond_2
invoke-static {p0}, Lkotlin/collections/CollectionsKt;->toHashSet(Ljava/lang/Iterable;)Ljava/util/HashSet;
move-result-object p0
check-cast p0, Ljava/util/Collection;
goto :goto_0
:cond_2
move-object p0, p1
goto :goto_0
.line 53
:cond_3
invoke-static {p0}, Lkotlin/collections/CollectionsKt;->toHashSet(Ljava/lang/Iterable;)Ljava/util/HashSet;
move-result-object p0
check-cast p0, Ljava/util/Collection;
:goto_0
return-object p0
.end method
.method public static final flatten(Ljava/lang/Iterable;)Ljava/util/List;
.locals 3
.param p0 # Ljava/lang/Iterable;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/Iterable<",
"+",
"Ljava/lang/Iterable<",
"+TT;>;>;)",
"Ljava/util/List<",
"TT;>;"
}
.end annotation
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
const-string v0, "$this$flatten"
invoke-static {p0, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
.line 70
new-instance v0, Ljava/util/ArrayList;
invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V
.line 71
invoke-interface {p0}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
move-result-object p0
:goto_0
invoke-interface {p0}, Ljava/util/Iterator;->hasNext()Z
move-result v1
if-eqz v1, :cond_0
invoke-interface {p0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v1
check-cast v1, Ljava/lang/Iterable;
.line 72
move-object v2, v0
check-cast v2, Ljava/util/Collection;
invoke-static {v2, v1}, Lkotlin/collections/CollectionsKt;->addAll(Ljava/util/Collection;Ljava/lang/Iterable;)Z
goto :goto_0
.line 74
:cond_0
check-cast v0, Ljava/util/List;
return-object v0
.end method
.method private static final safeToConvertToSet$CollectionsKt__IterablesKt(Ljava/util/Collection;)Z
.locals 2
.param p0 # Ljava/util/Collection;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Ljava/util/Collection<",
"+TT;>;)Z"
}
.end annotation
.line 42
invoke-interface {p0}, Ljava/util/Collection;->size()I
move-result v0
const/4 v1, 0x2
if-le v0, v1, :cond_0
instance-of p0, p0, Ljava/util/ArrayList;
if-eqz p0, :cond_0
const/4 p0, 0x1
goto :goto_0
:cond_0
const/4 p0, 0x0
:goto_0
return p0
.end method
.method public static final unzip(Ljava/lang/Iterable;)Lkotlin/Pair;
.locals 4
.param p0 # Ljava/lang/Iterable;
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
"R:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/Iterable<",
"+",
"Lkotlin/Pair<",
"+TT;+TR;>;>;)",
"Lkotlin/Pair<",
"Ljava/util/List<",
"TT;>;",
"Ljava/util/List<",
"TR;>;>;"
}
.end annotation
.annotation build Lorg/jetbrains/annotations/NotNull;
.end annotation
const-string v0, "$this$unzip"
invoke-static {p0, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
const/16 v0, 0xa
.line 84
invoke-static {p0, v0}, Lkotlin/collections/CollectionsKt;->collectionSizeOrDefault(Ljava/lang/Iterable;I)I
move-result v0
.line 85
new-instance v1, Ljava/util/ArrayList;
invoke-direct {v1, v0}, Ljava/util/ArrayList;-><init>(I)V
.line 86
new-instance v2, Ljava/util/ArrayList;
invoke-direct {v2, v0}, Ljava/util/ArrayList;-><init>(I)V
.line 87
invoke-interface {p0}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
move-result-object p0
:goto_0
invoke-interface {p0}, Ljava/util/Iterator;->hasNext()Z
move-result v0
if-eqz v0, :cond_0
invoke-interface {p0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v0
check-cast v0, Lkotlin/Pair;
.line 88
invoke-virtual {v0}, Lkotlin/Pair;->getFirst()Ljava/lang/Object;
move-result-object v3
invoke-virtual {v1, v3}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
.line 89
invoke-virtual {v0}, Lkotlin/Pair;->getSecond()Ljava/lang/Object;
move-result-object v0
invoke-virtual {v2, v0}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
goto :goto_0
.line 91
:cond_0
invoke-static {v1, v2}, Lkotlin/TuplesKt;->to(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
move-result-object p0
return-object p0
.end method