package com.google.android.m4b.maps.r;

import android.content.Context;
import android.os.Build.VERSION;
import android.os.RemoteException;
import com.google.android.m4b.maps.d.c;
import com.google.android.m4b.maps.g.l;
import com.google.android.m4b.maps.model.RuntimeRemoteException;

public class am
{
  private static Context a;
  private static f b;

  public static f a(Context paramContext)
  {
    l.a(paramContext);
    if (b != null)
      return b;
    int i = com.google.android.m4b.maps.d.d.a(paramContext);
    switch (i)
    {
    default:
      throw new c(i);
    case 0:
    }
    am.class.getSimpleName();
    b = (f)a(a());
    try
    {
      f localf = b;
      if (a == null)
        a = paramContext.getApplicationContext();
      localf.a(com.google.android.m4b.maps.j.d.a(a.getResources()), com.google.android.m4b.maps.d.d.a);
      return b;
    }
    catch (RemoteException localRemoteException)
    {
      throw new RuntimeRemoteException(localRemoteException);
    }
  }

  private static Class<?> a()
  {
    try
    {
      if (Build.VERSION.SDK_INT < 15)
        return Class.forName("com.google.android.m4b.maps.r.c");
      Class localClass = Class.forName("com.google.android.m4b.maps.r.b");
      return localClass;
    }
    catch (ClassNotFoundException localClassNotFoundException)
    {
      throw new RuntimeException(localClassNotFoundException);
    }
  }

  private static <T> T a(Class<?> paramClass)
  {
    try
    {
      Object localObject = paramClass.newInstance();
      return localObject;
    }
    catch (InstantiationException localInstantiationException)
    {
      throw new IllegalStateException("Unable to instantiate the dynamic class " + paramClass.getName());
    }
    catch (IllegalAccessException localIllegalAccessException)
    {
    }
    throw new IllegalStateException("Unable to call the default constructor of " + paramClass.getName());
  }
}

/* Location:           C:\Documents and Settings\Cesar Cabello Cea\Mis documentos\Downloads\apk-downloader\com.ikea.kompis-6_dex2jar.jar
 * Qualified Name:     com.google.android.m4b.maps.r.am
 * JD-Core Version:    0.6.2
 */