package com.google.common.collect;

import com.google.common.base.Ascii;
import com.google.common.base.Equivalence;
import com.google.common.base.Objects;
import com.google.common.base.Objects.ToStringHelper;
import com.google.common.base.Preconditions;
import com.google.common.base.Ticker;
import java.io.Serializable;
import java.util.AbstractMap;
import java.util.Collections;
import java.util.Map.Entry;
import java.util.Set;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
import javax.annotation.Nullable;

public final class MapMaker extends GenericMapMaker<Object, Object>
{
  int concurrencyLevel = -1;
  long expireAfterAccessNanos = -1L;
  long expireAfterWriteNanos = -1L;
  int initialCapacity = -1;
  Equivalence<Object> keyEquivalence;
  MapMakerInternalMap.Strength keyStrength;
  int maximumSize = -1;
  RemovalCause nullRemovalCause;
  Ticker ticker;
  boolean useCustomMap;
  MapMakerInternalMap.Strength valueStrength;

  int getConcurrencyLevel()
  {
    if (this.concurrencyLevel == -1)
      return 4;
    return this.concurrencyLevel;
  }

  long getExpireAfterAccessNanos()
  {
    if (this.expireAfterAccessNanos == -1L)
      return 0L;
    return this.expireAfterAccessNanos;
  }

  long getExpireAfterWriteNanos()
  {
    if (this.expireAfterWriteNanos == -1L)
      return 0L;
    return this.expireAfterWriteNanos;
  }

  int getInitialCapacity()
  {
    if (this.initialCapacity == -1)
      return 16;
    return this.initialCapacity;
  }

  Equivalence<Object> getKeyEquivalence()
  {
    return (Equivalence)Objects.firstNonNull(this.keyEquivalence, getKeyStrength().defaultEquivalence());
  }

  MapMakerInternalMap.Strength getKeyStrength()
  {
    return (MapMakerInternalMap.Strength)Objects.firstNonNull(this.keyStrength, MapMakerInternalMap.Strength.STRONG);
  }

  Ticker getTicker()
  {
    return (Ticker)Objects.firstNonNull(this.ticker, Ticker.systemTicker());
  }

  MapMakerInternalMap.Strength getValueStrength()
  {
    return (MapMakerInternalMap.Strength)Objects.firstNonNull(this.valueStrength, MapMakerInternalMap.Strength.STRONG);
  }

  public <K, V> ConcurrentMap<K, V> makeMap()
  {
    if (!this.useCustomMap)
      return new ConcurrentHashMap(getInitialCapacity(), 0.75F, getConcurrencyLevel());
    if (this.nullRemovalCause == null);
    for (Object localObject = new MapMakerInternalMap(this); ; localObject = new NullConcurrentMap(this))
      return (ConcurrentMap)localObject;
  }

  public String toString()
  {
    Objects.ToStringHelper localToStringHelper = Objects.toStringHelper(this);
    if (this.initialCapacity != -1)
      localToStringHelper.add("initialCapacity", this.initialCapacity);
    if (this.concurrencyLevel != -1)
      localToStringHelper.add("concurrencyLevel", this.concurrencyLevel);
    if (this.maximumSize != -1)
      localToStringHelper.add("maximumSize", this.maximumSize);
    if (this.expireAfterWriteNanos != -1L)
      localToStringHelper.add("expireAfterWrite", this.expireAfterWriteNanos + "ns");
    if (this.expireAfterAccessNanos != -1L)
      localToStringHelper.add("expireAfterAccess", this.expireAfterAccessNanos + "ns");
    if (this.keyStrength != null)
      localToStringHelper.add("keyStrength", Ascii.toLowerCase(this.keyStrength.toString()));
    if (this.valueStrength != null)
      localToStringHelper.add("valueStrength", Ascii.toLowerCase(this.valueStrength.toString()));
    if (this.keyEquivalence != null)
      localToStringHelper.addValue("keyEquivalence");
    if (this.removalListener != null)
      localToStringHelper.addValue("removalListener");
    return localToStringHelper.toString();
  }

  static class NullConcurrentMap<K, V> extends AbstractMap<K, V>
    implements Serializable, ConcurrentMap<K, V>
  {
    private final MapMaker.RemovalCause removalCause;
    private final MapMaker.RemovalListener<K, V> removalListener;

    NullConcurrentMap(MapMaker paramMapMaker)
    {
      this.removalListener = paramMapMaker.getRemovalListener();
      this.removalCause = paramMapMaker.nullRemovalCause;
    }

    public boolean containsKey(@Nullable Object paramObject)
    {
      return false;
    }

    public boolean containsValue(@Nullable Object paramObject)
    {
      return false;
    }

    public Set<Map.Entry<K, V>> entrySet()
    {
      return Collections.emptySet();
    }

    public V get(@Nullable Object paramObject)
    {
      return null;
    }

    void notifyRemoval(K paramK, V paramV)
    {
      MapMaker.RemovalNotification localRemovalNotification = new MapMaker.RemovalNotification(paramK, paramV, this.removalCause);
      this.removalListener.onRemoval(localRemovalNotification);
    }

    public V put(K paramK, V paramV)
    {
      Preconditions.checkNotNull(paramK);
      Preconditions.checkNotNull(paramV);
      notifyRemoval(paramK, paramV);
      return null;
    }

    public V putIfAbsent(K paramK, V paramV)
    {
      return put(paramK, paramV);
    }

    public V remove(@Nullable Object paramObject)
    {
      return null;
    }

    public boolean remove(@Nullable Object paramObject1, @Nullable Object paramObject2)
    {
      return false;
    }

    public V replace(K paramK, V paramV)
    {
      Preconditions.checkNotNull(paramK);
      Preconditions.checkNotNull(paramV);
      return null;
    }

    public boolean replace(K paramK, @Nullable V paramV1, V paramV2)
    {
      Preconditions.checkNotNull(paramK);
      Preconditions.checkNotNull(paramV2);
      return false;
    }
  }

  static abstract enum RemovalCause
  {
    static
    {
      // Byte code:
      //   0: new 17	com/google/common/collect/MapMaker$RemovalCause$1
      //   3: dup
      //   4: ldc 18
      //   6: iconst_0
      //   7: invokespecial 22	com/google/common/collect/MapMaker$RemovalCause$1:<init>	(Ljava/lang/String;I)V
      //   10: putstatic 24	com/google/common/collect/MapMaker$RemovalCause:EXPLICIT	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   13: new 26	com/google/common/collect/MapMaker$RemovalCause$2
      //   16: dup
      //   17: ldc 27
      //   19: iconst_1
      //   20: invokespecial 28	com/google/common/collect/MapMaker$RemovalCause$2:<init>	(Ljava/lang/String;I)V
      //   23: putstatic 30	com/google/common/collect/MapMaker$RemovalCause:REPLACED	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   26: new 32	com/google/common/collect/MapMaker$RemovalCause$3
      //   29: dup
      //   30: ldc 33
      //   32: iconst_2
      //   33: invokespecial 34	com/google/common/collect/MapMaker$RemovalCause$3:<init>	(Ljava/lang/String;I)V
      //   36: putstatic 36	com/google/common/collect/MapMaker$RemovalCause:COLLECTED	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   39: new 38	com/google/common/collect/MapMaker$RemovalCause$4
      //   42: dup
      //   43: ldc 39
      //   45: iconst_3
      //   46: invokespecial 40	com/google/common/collect/MapMaker$RemovalCause$4:<init>	(Ljava/lang/String;I)V
      //   49: putstatic 42	com/google/common/collect/MapMaker$RemovalCause:EXPIRED	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   52: new 44	com/google/common/collect/MapMaker$RemovalCause$5
      //   55: dup
      //   56: ldc 45
      //   58: iconst_4
      //   59: invokespecial 46	com/google/common/collect/MapMaker$RemovalCause$5:<init>	(Ljava/lang/String;I)V
      //   62: putstatic 48	com/google/common/collect/MapMaker$RemovalCause:SIZE	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   65: iconst_5
      //   66: anewarray 2	com/google/common/collect/MapMaker$RemovalCause
      //   69: astore_0
      //   70: aload_0
      //   71: iconst_0
      //   72: getstatic 24	com/google/common/collect/MapMaker$RemovalCause:EXPLICIT	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   75: aastore
      //   76: aload_0
      //   77: iconst_1
      //   78: getstatic 30	com/google/common/collect/MapMaker$RemovalCause:REPLACED	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   81: aastore
      //   82: aload_0
      //   83: iconst_2
      //   84: getstatic 36	com/google/common/collect/MapMaker$RemovalCause:COLLECTED	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   87: aastore
      //   88: aload_0
      //   89: iconst_3
      //   90: getstatic 42	com/google/common/collect/MapMaker$RemovalCause:EXPIRED	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   93: aastore
      //   94: aload_0
      //   95: iconst_4
      //   96: getstatic 48	com/google/common/collect/MapMaker$RemovalCause:SIZE	Lcom/google/common/collect/MapMaker$RemovalCause;
      //   99: aastore
      //   100: aload_0
      //   101: putstatic 50	com/google/common/collect/MapMaker$RemovalCause:$VALUES	[Lcom/google/common/collect/MapMaker$RemovalCause;
      //   104: return
    }
  }

  static abstract interface RemovalListener<K, V>
  {
    public abstract void onRemoval(MapMaker.RemovalNotification<K, V> paramRemovalNotification);
  }

  static final class RemovalNotification<K, V> extends ImmutableEntry<K, V>
  {
    private final MapMaker.RemovalCause cause;

    RemovalNotification(@Nullable K paramK, @Nullable V paramV, MapMaker.RemovalCause paramRemovalCause)
    {
      super(paramV);
      this.cause = paramRemovalCause;
    }
  }
}

/* Location:           C:\Documents and Settings\Cesar Cabello Cea\Mis documentos\Downloads\apk-downloader\com.ikea.kompis-6_dex2jar.jar
 * Qualified Name:     com.google.common.collect.MapMaker
 * JD-Core Version:    0.6.2
 */