ObservableCombineLatest.smali
.class public final Lio/reactivex/internal/operators/observable/ObservableCombineLatest;
.super Lio/reactivex/Observable;
.source "ObservableCombineLatest.java"
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lio/reactivex/internal/operators/observable/ObservableCombineLatest$CombinerObserver;,
Lio/reactivex/internal/operators/observable/ObservableCombineLatest$LatestCoordinator;
}
.end annotation
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
"R:",
"Ljava/lang/Object;",
">",
"Lio/reactivex/Observable<",
"TR;>;"
}
.end annotation
# instance fields
.field final bufferSize:I
.field final combiner:Lio/reactivex/functions/Function;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lio/reactivex/functions/Function<",
"-[",
"Ljava/lang/Object;",
"+TR;>;"
}
.end annotation
.end field
.field final delayError:Z
.field final sources:[Lio/reactivex/ObservableSource;
.annotation system Ldalvik/annotation/Signature;
value = {
"[",
"Lio/reactivex/ObservableSource<",
"+TT;>;"
}
.end annotation
.end field
.field final sourcesIterable:Ljava/lang/Iterable;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/lang/Iterable<",
"+",
"Lio/reactivex/ObservableSource<",
"+TT;>;>;"
}
.end annotation
.end field
# direct methods
.method static constructor <clinit>()V
.registers 1
return-void
.end method
.method public constructor <init>([Lio/reactivex/ObservableSource;Ljava/lang/Iterable;Lio/reactivex/functions/Function;IZ)V
.registers 6
.param p4, "bufferSize" # I
.param p5, "delayError" # Z
.annotation system Ldalvik/annotation/Signature;
value = {
"([",
"Lio/reactivex/ObservableSource<",
"+TT;>;",
"Ljava/lang/Iterable<",
"+",
"Lio/reactivex/ObservableSource<",
"+TT;>;>;",
"Lio/reactivex/functions/Function<",
"-[",
"Ljava/lang/Object;",
"+TR;>;IZ)V"
}
.end annotation
.line 38
.local p0, "this":Lio/reactivex/internal/operators/observable/ObservableCombineLatest;, "Lio/reactivex/internal/operators/observable/ObservableCombineLatest<TT;TR;>;"
.local p1, "sources":[Lio/reactivex/ObservableSource;, "[Lio/reactivex/ObservableSource<+TT;>;"
.local p2, "sourcesIterable":Ljava/lang/Iterable;, "Ljava/lang/Iterable<+Lio/reactivex/ObservableSource<+TT;>;>;"
.local p3, "combiner":Lio/reactivex/functions/Function;, "Lio/reactivex/functions/Function<-[Ljava/lang/Object;+TR;>;"
invoke-direct {p0}, Lio/reactivex/Observable;-><init>()V
.line 39
iput-object p1, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->sources:[Lio/reactivex/ObservableSource;
.line 40
iput-object p2, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->sourcesIterable:Ljava/lang/Iterable;
.line 41
iput-object p3, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->combiner:Lio/reactivex/functions/Function;
.line 42
iput p4, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->bufferSize:I
.line 43
iput-boolean p5, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->delayError:Z
.line 44
return-void
.end method
# virtual methods
.method public subscribeActual(Lio/reactivex/Observer;)V
.registers 11
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lio/reactivex/Observer<",
"-TR;>;)V"
}
.end annotation
.line 50
.local p0, "this":Lio/reactivex/internal/operators/observable/ObservableCombineLatest;, "Lio/reactivex/internal/operators/observable/ObservableCombineLatest<TT;TR;>;"
.local p1, "s":Lio/reactivex/Observer;, "Lio/reactivex/Observer<-TR;>;"
iget-object v0, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->sources:[Lio/reactivex/ObservableSource;
.line 51
.local v0, "sources":[Lio/reactivex/ObservableSource;, "[Lio/reactivex/ObservableSource<+TT;>;"
const/4 v1, 0x0
.line 52
.local v1, "count":I
if-nez v0, :cond_30
.line 53
const/16 v2, 0x8
new-array v0, v2, [Lio/reactivex/Observable;
.line 54
iget-object v2, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->sourcesIterable:Ljava/lang/Iterable;
invoke-interface {v2}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
move-result-object v2
:goto_f
invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z
move-result v3
if-eqz v3, :cond_2e
invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v3
check-cast v3, Lio/reactivex/ObservableSource;
.line 55
.local v3, "p":Lio/reactivex/ObservableSource;, "Lio/reactivex/ObservableSource<+TT;>;"
array-length v4, v0
if-ne v1, v4, :cond_28
.line 56
shr-int/lit8 v4, v1, 0x2
add-int/2addr v4, v1
new-array v4, v4, [Lio/reactivex/ObservableSource;
.line 57
.local v4, "b":[Lio/reactivex/ObservableSource;, "[Lio/reactivex/ObservableSource<+TT;>;"
const/4 v5, 0x0
invoke-static {v0, v5, v4, v5, v1}, Ljava/lang/System;->arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V
.line 58
move-object v0, v4
.line 60
.end local v4 # "b":[Lio/reactivex/ObservableSource;, "[Lio/reactivex/ObservableSource<+TT;>;"
:cond_28
add-int/lit8 v4, v1, 0x1
.end local v1 # "count":I
.local v4, "count":I
aput-object v3, v0, v1
.line 61
.end local v3 # "p":Lio/reactivex/ObservableSource;, "Lio/reactivex/ObservableSource<+TT;>;"
move v1, v4
goto :goto_f
.end local v4 # "count":I
.restart local v1 # "count":I
:cond_2e
move v7, v1
goto :goto_32
.line 63
:cond_30
array-length v1, v0
move v7, v1
.line 66
.end local v1 # "count":I
.local v7, "count":I
:goto_32
if-nez v7, :cond_38
.line 67
invoke-static {p1}, Lio/reactivex/internal/disposables/EmptyDisposable;->complete(Lio/reactivex/Observer;)V
.line 68
return-void
.line 71
:cond_38
new-instance v8, Lio/reactivex/internal/operators/observable/ObservableCombineLatest$LatestCoordinator;
iget-object v3, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->combiner:Lio/reactivex/functions/Function;
iget v5, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->bufferSize:I
iget-boolean v6, p0, Lio/reactivex/internal/operators/observable/ObservableCombineLatest;->delayError:Z
move-object v1, v8
move-object v2, p1
move v4, v7
invoke-direct/range {v1 .. v6}, Lio/reactivex/internal/operators/observable/ObservableCombineLatest$LatestCoordinator;-><init>(Lio/reactivex/Observer;Lio/reactivex/functions/Function;IIZ)V
.line 72
.local v1, "lc":Lio/reactivex/internal/operators/observable/ObservableCombineLatest$LatestCoordinator;, "Lio/reactivex/internal/operators/observable/ObservableCombineLatest$LatestCoordinator<TT;TR;>;"
invoke-virtual {v1, v0}, Lio/reactivex/internal/operators/observable/ObservableCombineLatest$LatestCoordinator;->subscribe([Lio/reactivex/ObservableSource;)V
.line 73
return-void
.end method