package com.bytedance.android.livesdk.gift.model;

import X.0SJ;
import X.0SP;
import X.0SQ;
import com.bytedance.android.live.base.model._ImageModel_ProtoDecoder;
import com.bytedance.android.livesdk.livesetting.linkmic.MtCoHostReceiveInviteMessageTimeOutSetting;
import com.bytedance.android.livesdk.livesetting.wallet.LiveRechargeAgeThresholdSetting;
import com.bytedance.covode.number.Covode;
import java.util.ArrayList;

public final class _GiftsInfo_ProtoDecoder implements 0SJ<GiftsInfo> {
    static {
        Covode.recordClassIndex(16469);
    }

    public final /* synthetic */ Object LIZIZ(0SP r2) {
        return LIZ(r2);
    }

    public static GiftsInfo LIZ(0SP r5) {
        GiftsInfo giftsInfo = new GiftsInfo();
        giftsInfo.LJIILJJIL = new ArrayList();
        giftsInfo.LJFF = new ArrayList();
        long LIZ = r5.LIZ();
        while (true) {
            int LIZIZ = r5.LIZIZ();
            if (LIZIZ == -1) {
                r5.LIZ(LIZ);
                return giftsInfo;
            } else if (LIZIZ == 1) {
                giftsInfo.LJIIL = Long.valueOf(0SQ.LIZIZ(r5));
            } else if (LIZIZ == 3) {
                giftsInfo.LIZ = 0SQ.LIZIZ(r5);
            } else if (LIZIZ == 4) {
                giftsInfo.LJIILIIL = r5.LIZLLL();
            } else if (LIZIZ == 5) {
                giftsInfo.LJIILJJIL.add(_GiftGroupCount_ProtoDecoder.LIZ(r5));
            } else if (LIZIZ == 10) {
                giftsInfo.LIZJ = 0SQ.LIZ(r5);
            } else if (LIZIZ != 11) {
                switch (LIZIZ) {
                    case 13:
                        giftsInfo.LJFF.add(_GiftComboInfo_ProtoDecoder.LIZ(r5));
                        break;
                    case 14:
                        giftsInfo.LJI = Boolean.valueOf(0SQ.LIZ(r5));
                        break;
                    case MtCoHostReceiveInviteMessageTimeOutSetting.DEFAULT /*15*/:
                        giftsInfo.LJII = Boolean.valueOf(0SQ.LIZ(r5));
                        break;
                    case 16:
                        giftsInfo.LIZIZ = _LiveLimitedTimeDiscountGiftInfo_ProtoDecoder.LIZ(r5);
                        break;
                    case 17:
                        giftsInfo.LJIIIIZZ = _LiveLimitedTimeDiscountGiftInfo_ProtoDecoder.LIZ(r5);
                        break;
                    case LiveRechargeAgeThresholdSetting.DEFAULT /*18*/:
                        giftsInfo.LIZLLL = _GiftIconInfo_ProtoDecoder.LIZ(r5);
                        break;
                    case 19:
                        giftsInfo.LJIIIZ = Long.valueOf(0SQ.LIZIZ(r5));
                        break;
                    case 20:
                        giftsInfo.LJIIJ = Long.valueOf(0SQ.LIZIZ(r5));
                        break;
                    case 21:
                        giftsInfo.LJIIJJI = _ImageModel_ProtoDecoder.LIZ(r5);
                        break;
                    case 22:
                        giftsInfo.LJIIZILJ = Long.valueOf(0SQ.LIZIZ(r5));
                        break;
                    case 23:
                        giftsInfo.LJIILL = _GiftPollInfo_ProtoDecoder.LIZ(r5);
                        break;
                    case 24:
                        giftsInfo.LJIJ = _RiskCtl_ProtoDecoder.LIZ(r5);
                        break;
                    case 25:
                        giftsInfo.LJIILLIIL = _FreqLimitGiftInfo_ProtoDecoder.LIZ(r5);
                        break;
                    case 26:
                        giftsInfo.LJIJI = 0SQ.LIZ(r5);
                        break;
                    default:
                        0SQ.LIZJ(r5);
                        break;
                }
            } else {
                giftsInfo.LJ = _ImageModel_ProtoDecoder.LIZ(r5);
            }
        }
    }
}
