package ῲ.ݜ;

import android.content.Context;
import android.media.browse.MediaBrowser;
import android.os.Bundle;
import android.os.Parcel;
import android.service.media.MediaBrowserService;
import android.support.v4.media.session.MediaSessionCompat;
import android.util.Log;
import androidx.media.MediaBrowserServiceCompat;
import java.lang.reflect.Field;
import java.util.ArrayList;
import java.util.List;

/* renamed from: ῲ.ݜ.䁗  reason: contains not printable characters */
/* compiled from: MediaBrowserServiceCompatApi26 */
public class C1606 {

    /* renamed from: K  reason: contains not printable characters */
    public static Field f5790;

    /* renamed from: ῲ.ݜ.䁗$ʬ  reason: contains not printable characters */
    /* compiled from: MediaBrowserServiceCompatApi26 */
    public interface AbstractC1607 extends AbstractC1598 {
    }

    /* renamed from: ῲ.ݜ.䁗$ῲ  reason: contains not printable characters */
    /* compiled from: MediaBrowserServiceCompatApi26 */
    public static class C1608 {

        /* renamed from: K  reason: contains not printable characters */
        public MediaBrowserService.Result f5791;

        public C1608(MediaBrowserService.Result result) {
            this.f5791 = result;
        }

        /* renamed from: K  reason: contains not printable characters */
        public void m4150(List<Parcel> list, int i) {
            ArrayList arrayList;
            try {
                C1606.f5790.setInt(this.f5791, i);
            } catch (IllegalAccessException e) {
                Log.w("MBSCompatApi26", e);
            }
            MediaBrowserService.Result result = this.f5791;
            if (list == null) {
                arrayList = null;
            } else {
                ArrayList arrayList2 = new ArrayList();
                for (Parcel parcel : list) {
                    parcel.setDataPosition(0);
                    arrayList2.add(MediaBrowser.MediaItem.CREATOR.createFromParcel(parcel));
                    parcel.recycle();
                }
                arrayList = arrayList2;
            }
            result.sendResult(arrayList);
        }
    }

    /* renamed from: ῲ.ݜ.䁗$K  reason: contains not printable characters */
    /* compiled from: MediaBrowserServiceCompatApi26 */
    public static class C1609 extends C1593 {
        public C1609(Context context, AbstractC1607 r2) {
            super(context, r2);
        }

        @Override // android.service.media.MediaBrowserService
        public void onLoadChildren(String str, MediaBrowserService.Result<List<MediaBrowser.MediaItem>> result, Bundle bundle) {
            MediaSessionCompat.ensureClassLoader(bundle);
            ((MediaBrowserServiceCompat.C0211) this.f5789).m755(str, new C1608(result), bundle);
        }
    }

    static {
        try {
            f5790 = MediaBrowserService.Result.class.getDeclaredField("mFlags");
            f5790.setAccessible(true);
        } catch (NoSuchFieldException e) {
            Log.w("MBSCompatApi26", e);
        }
    }

    /* renamed from: K  reason: contains not printable characters */
    public static Object m4149(Context context, AbstractC1607 r2) {
        return new C1609(context, r2);
    }
}
