268 lines
		
	
	
		
			6.4 KiB
		
	
	
	
		
			Smali
		
	
	
	
	
	
			
		
		
	
	
			268 lines
		
	
	
		
			6.4 KiB
		
	
	
	
		
			Smali
		
	
	
	
	
	
| .class final Lcom/google/common/collect/Collections2$OrderedPermutationCollection;
 | |
| .super Ljava/util/AbstractCollection;
 | |
| .source "Collections2.java"
 | |
| 
 | |
| 
 | |
| # annotations
 | |
| .annotation system Ldalvik/annotation/EnclosingClass;
 | |
|     value = Lcom/google/common/collect/Collections2;
 | |
| .end annotation
 | |
| 
 | |
| .annotation system Ldalvik/annotation/InnerClass;
 | |
|     accessFlags = 0x19
 | |
|     name = "OrderedPermutationCollection"
 | |
| .end annotation
 | |
| 
 | |
| .annotation system Ldalvik/annotation/Signature;
 | |
|     value = {
 | |
|         "<E:",
 | |
|         "Ljava/lang/Object;",
 | |
|         ">",
 | |
|         "Ljava/util/AbstractCollection<",
 | |
|         "Ljava/util/List<",
 | |
|         "TE;>;>;"
 | |
|     }
 | |
| .end annotation
 | |
| 
 | |
| 
 | |
| # instance fields
 | |
| .field public final comparator:Ljava/util/Comparator;
 | |
|     .annotation system Ldalvik/annotation/Signature;
 | |
|         value = {
 | |
|             "Ljava/util/Comparator<",
 | |
|             "-TE;>;"
 | |
|         }
 | |
|     .end annotation
 | |
| .end field
 | |
| 
 | |
| .field public final inputList:Lcom/google/common/collect/ImmutableList;
 | |
|     .annotation system Ldalvik/annotation/Signature;
 | |
|         value = {
 | |
|             "Lcom/google/common/collect/ImmutableList<",
 | |
|             "TE;>;"
 | |
|         }
 | |
|     .end annotation
 | |
| .end field
 | |
| 
 | |
| .field public final size:I
 | |
| 
 | |
| 
 | |
| # direct methods
 | |
| .method public constructor <init>(Ljava/lang/Iterable;Ljava/util/Comparator;)V
 | |
|     .locals 0
 | |
|     .annotation system Ldalvik/annotation/Signature;
 | |
|         value = {
 | |
|             "(",
 | |
|             "Ljava/lang/Iterable<",
 | |
|             "TE;>;",
 | |
|             "Ljava/util/Comparator<",
 | |
|             "-TE;>;)V"
 | |
|         }
 | |
|     .end annotation
 | |
| 
 | |
|     .line 1
 | |
|     invoke-direct {p0}, Ljava/util/AbstractCollection;-><init>()V
 | |
| 
 | |
|     .line 2
 | |
|     invoke-static {p2, p1}, Lcom/google/common/collect/ImmutableList;->sortedCopyOf(Ljava/util/Comparator;Ljava/lang/Iterable;)Lcom/google/common/collect/ImmutableList;
 | |
| 
 | |
|     move-result-object p1
 | |
| 
 | |
|     iput-object p1, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->inputList:Lcom/google/common/collect/ImmutableList;
 | |
| 
 | |
|     .line 3
 | |
|     iput-object p2, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->comparator:Ljava/util/Comparator;
 | |
| 
 | |
|     .line 4
 | |
|     invoke-static {p1, p2}, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->calculateSize(Ljava/util/List;Ljava/util/Comparator;)I
 | |
| 
 | |
|     move-result p1
 | |
| 
 | |
|     iput p1, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->size:I
 | |
| 
 | |
|     return-void
 | |
| .end method
 | |
| 
 | |
| .method private static calculateSize(Ljava/util/List;Ljava/util/Comparator;)I
 | |
|     .locals 6
 | |
|     .annotation system Ldalvik/annotation/Signature;
 | |
|         value = {
 | |
|             "<E:",
 | |
|             "Ljava/lang/Object;",
 | |
|             ">(",
 | |
|             "Ljava/util/List<",
 | |
|             "TE;>;",
 | |
|             "Ljava/util/Comparator<",
 | |
|             "-TE;>;)I"
 | |
|         }
 | |
|     .end annotation
 | |
| 
 | |
|     const/4 v0, 0x1
 | |
| 
 | |
|     move v1, v0
 | |
| 
 | |
|     move v2, v1
 | |
| 
 | |
|     move v3, v2
 | |
| 
 | |
|     .line 1
 | |
|     :goto_0
 | |
|     invoke-interface {p0}, Ljava/util/List;->size()I
 | |
| 
 | |
|     move-result v4
 | |
| 
 | |
|     if-ge v1, v4, :cond_1
 | |
| 
 | |
|     add-int/lit8 v4, v1, -0x1
 | |
| 
 | |
|     .line 2
 | |
|     invoke-interface {p0, v4}, Ljava/util/List;->get(I)Ljava/lang/Object;
 | |
| 
 | |
|     move-result-object v4
 | |
| 
 | |
|     invoke-interface {p0, v1}, Ljava/util/List;->get(I)Ljava/lang/Object;
 | |
| 
 | |
|     move-result-object v5
 | |
| 
 | |
|     invoke-interface {p1, v4, v5}, Ljava/util/Comparator;->compare(Ljava/lang/Object;Ljava/lang/Object;)I
 | |
| 
 | |
|     move-result v4
 | |
| 
 | |
|     if-gez v4, :cond_0
 | |
| 
 | |
|     .line 3
 | |
|     invoke-static {v1, v3}, Lcom/google/common/math/IntMath;->binomial(II)I
 | |
| 
 | |
|     move-result v3
 | |
| 
 | |
|     invoke-static {v2, v3}, Lcom/google/common/math/IntMath;->saturatedMultiply(II)I
 | |
| 
 | |
|     move-result v2
 | |
| 
 | |
|     const/4 v3, 0x0
 | |
| 
 | |
|     const v4, 0x7fffffff
 | |
| 
 | |
|     if-ne v2, v4, :cond_0
 | |
| 
 | |
|     return v4
 | |
| 
 | |
|     :cond_0
 | |
|     add-int/lit8 v1, v1, 0x1
 | |
| 
 | |
|     add-int/2addr v3, v0
 | |
| 
 | |
|     goto :goto_0
 | |
| 
 | |
|     .line 4
 | |
|     :cond_1
 | |
|     invoke-static {v1, v3}, Lcom/google/common/math/IntMath;->binomial(II)I
 | |
| 
 | |
|     move-result p0
 | |
| 
 | |
|     invoke-static {v2, p0}, Lcom/google/common/math/IntMath;->saturatedMultiply(II)I
 | |
| 
 | |
|     move-result p0
 | |
| 
 | |
|     return p0
 | |
| .end method
 | |
| 
 | |
| 
 | |
| # virtual methods
 | |
| .method public contains(Ljava/lang/Object;)Z
 | |
|     .locals 1
 | |
|     .param p1    # Ljava/lang/Object;
 | |
|         .annotation runtime Ljavax/annotation/CheckForNull;
 | |
|         .end annotation
 | |
|     .end param
 | |
| 
 | |
|     .line 1
 | |
|     instance-of v0, p1, Ljava/util/List;
 | |
| 
 | |
|     if-eqz v0, :cond_0
 | |
| 
 | |
|     .line 2
 | |
|     check-cast p1, Ljava/util/List;
 | |
| 
 | |
|     .line 3
 | |
|     iget-object v0, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->inputList:Lcom/google/common/collect/ImmutableList;
 | |
| 
 | |
|     invoke-static {v0, p1}, Lcom/google/common/collect/Collections2;->access$000(Ljava/util/List;Ljava/util/List;)Z
 | |
| 
 | |
|     move-result p1
 | |
| 
 | |
|     return p1
 | |
| 
 | |
|     :cond_0
 | |
|     const/4 p1, 0x0
 | |
| 
 | |
|     return p1
 | |
| .end method
 | |
| 
 | |
| .method public isEmpty()Z
 | |
|     .locals 1
 | |
| 
 | |
|     const/4 v0, 0x0
 | |
| 
 | |
|     return v0
 | |
| .end method
 | |
| 
 | |
| .method public iterator()Ljava/util/Iterator;
 | |
|     .locals 3
 | |
|     .annotation system Ldalvik/annotation/Signature;
 | |
|         value = {
 | |
|             "()",
 | |
|             "Ljava/util/Iterator<",
 | |
|             "Ljava/util/List<",
 | |
|             "TE;>;>;"
 | |
|         }
 | |
|     .end annotation
 | |
| 
 | |
|     .line 1
 | |
|     new-instance v0, Lcom/google/common/collect/Collections2$OrderedPermutationIterator;
 | |
| 
 | |
|     iget-object v1, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->inputList:Lcom/google/common/collect/ImmutableList;
 | |
| 
 | |
|     iget-object v2, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->comparator:Ljava/util/Comparator;
 | |
| 
 | |
|     invoke-direct {v0, v1, v2}, Lcom/google/common/collect/Collections2$OrderedPermutationIterator;-><init>(Ljava/util/List;Ljava/util/Comparator;)V
 | |
| 
 | |
|     return-object v0
 | |
| .end method
 | |
| 
 | |
| .method public size()I
 | |
|     .locals 1
 | |
| 
 | |
|     .line 1
 | |
|     iget v0, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->size:I
 | |
| 
 | |
|     return v0
 | |
| .end method
 | |
| 
 | |
| .method public toString()Ljava/lang/String;
 | |
|     .locals 4
 | |
| 
 | |
|     .line 1
 | |
|     iget-object v0, p0, Lcom/google/common/collect/Collections2$OrderedPermutationCollection;->inputList:Lcom/google/common/collect/ImmutableList;
 | |
| 
 | |
|     invoke-static {v0}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
 | |
| 
 | |
|     move-result-object v0
 | |
| 
 | |
|     invoke-virtual {v0}, Ljava/lang/String;->length()I
 | |
| 
 | |
|     move-result v1
 | |
| 
 | |
|     add-int/lit8 v1, v1, 0x1e
 | |
| 
 | |
|     const-string v2, "orderedPermutationCollection("
 | |
| 
 | |
|     const-string v3, ")"
 | |
| 
 | |
|     invoke-static {v1, v2, v0, v3}, Lcom/google/android/gms/ads/internal/a;->a(ILjava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
 | |
| 
 | |
|     move-result-object v0
 | |
| 
 | |
|     return-object v0
 | |
| .end method
 |