.class public final Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture; .super Ljava/lang/Object; .source "CallbackToFutureAdapter.java" # interfaces .implements Lf/h/b/a/a/a; # annotations .annotation system Ldalvik/annotation/EnclosingClass; value = Landroidx/concurrent/futures/CallbackToFutureAdapter; .end annotation .annotation system Ldalvik/annotation/InnerClass; accessFlags = 0x19 name = "SafeFuture" .end annotation .annotation system Ldalvik/annotation/Signature; value = { "", "Ljava/lang/Object;", "Lf/h/b/a/a/a<", "TT;>;" } .end annotation # instance fields .field public final completerWeakReference:Ljava/lang/ref/WeakReference; .annotation system Ldalvik/annotation/Signature; value = { "Ljava/lang/ref/WeakReference<", "Landroidx/concurrent/futures/CallbackToFutureAdapter$Completer<", "TT;>;>;" } .end annotation .end field .field private final delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; .annotation system Ldalvik/annotation/Signature; value = { "Landroidx/concurrent/futures/AbstractResolvableFuture<", "TT;>;" } .end annotation .end field # direct methods .method public constructor (Landroidx/concurrent/futures/CallbackToFutureAdapter$Completer;)V .locals 1 .annotation system Ldalvik/annotation/Signature; value = { "(", "Landroidx/concurrent/futures/CallbackToFutureAdapter$Completer<", "TT;>;)V" } .end annotation invoke-direct {p0}, Ljava/lang/Object;->()V new-instance v0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture$1; invoke-direct {v0, p0}, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture$1;->(Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;)V iput-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; new-instance v0, Ljava/lang/ref/WeakReference; invoke-direct {v0, p1}, Ljava/lang/ref/WeakReference;->(Ljava/lang/Object;)V iput-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->completerWeakReference:Ljava/lang/ref/WeakReference; return-void .end method # virtual methods .method public addListener(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V .locals 1 .param p1 # Ljava/lang/Runnable; .annotation build Landroidx/annotation/NonNull; .end annotation .end param .param p2 # Ljava/util/concurrent/Executor; .annotation build Landroidx/annotation/NonNull; .end annotation .end param iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0, p1, p2}, Landroidx/concurrent/futures/AbstractResolvableFuture;->addListener(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V return-void .end method .method public cancel(Z)Z .locals 2 iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->completerWeakReference:Ljava/lang/ref/WeakReference; invoke-virtual {v0}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object; move-result-object v0 check-cast v0, Landroidx/concurrent/futures/CallbackToFutureAdapter$Completer; iget-object v1, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v1, p1}, Landroidx/concurrent/futures/AbstractResolvableFuture;->cancel(Z)Z move-result p1 if-eqz p1, :cond_0 if-eqz v0, :cond_0 invoke-virtual {v0}, Landroidx/concurrent/futures/CallbackToFutureAdapter$Completer;->fireCancellationListeners()V :cond_0 return p1 .end method .method public cancelWithoutNotifyingCompleter(Z)Z .locals 1 iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0, p1}, Landroidx/concurrent/futures/AbstractResolvableFuture;->cancel(Z)Z move-result p1 return p1 .end method .method public get()Ljava/lang/Object; .locals 1 .annotation system Ldalvik/annotation/Signature; value = { "()TT;" } .end annotation .annotation system Ldalvik/annotation/Throws; value = { Ljava/lang/InterruptedException;, Ljava/util/concurrent/ExecutionException; } .end annotation iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0}, Landroidx/concurrent/futures/AbstractResolvableFuture;->get()Ljava/lang/Object; move-result-object v0 return-object v0 .end method .method public get(JLjava/util/concurrent/TimeUnit;)Ljava/lang/Object; .locals 1 .param p3 # Ljava/util/concurrent/TimeUnit; .annotation build Landroidx/annotation/NonNull; .end annotation .end param .annotation system Ldalvik/annotation/Signature; value = { "(J", "Ljava/util/concurrent/TimeUnit;", ")TT;" } .end annotation .annotation system Ldalvik/annotation/Throws; value = { Ljava/lang/InterruptedException;, Ljava/util/concurrent/ExecutionException;, Ljava/util/concurrent/TimeoutException; } .end annotation iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0, p1, p2, p3}, Landroidx/concurrent/futures/AbstractResolvableFuture;->get(JLjava/util/concurrent/TimeUnit;)Ljava/lang/Object; move-result-object p1 return-object p1 .end method .method public isCancelled()Z .locals 1 iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0}, Landroidx/concurrent/futures/AbstractResolvableFuture;->isCancelled()Z move-result v0 return v0 .end method .method public isDone()Z .locals 1 iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0}, Landroidx/concurrent/futures/AbstractResolvableFuture;->isDone()Z move-result v0 return v0 .end method .method public set(Ljava/lang/Object;)Z .locals 1 .annotation system Ldalvik/annotation/Signature; value = { "(TT;)Z" } .end annotation iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0, p1}, Landroidx/concurrent/futures/AbstractResolvableFuture;->set(Ljava/lang/Object;)Z move-result p1 return p1 .end method .method public setException(Ljava/lang/Throwable;)Z .locals 1 iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0, p1}, Landroidx/concurrent/futures/AbstractResolvableFuture;->setException(Ljava/lang/Throwable;)Z move-result p1 return p1 .end method .method public toString()Ljava/lang/String; .locals 1 iget-object v0, p0, Landroidx/concurrent/futures/CallbackToFutureAdapter$SafeFuture;->delegate:Landroidx/concurrent/futures/AbstractResolvableFuture; invoke-virtual {v0}, Landroidx/concurrent/futures/AbstractResolvableFuture;->toString()Ljava/lang/String; move-result-object v0 return-object v0 .end method