package com.cvte.tv.api;

import android.os.RemoteException;
import com.cvte.tv.api.aidl.EntityCecDevice;
import com.cvte.tv.api.aidl.EnumResetLevel;
import com.cvte.tv.api.aidl.ITVApiSystemCecAidl;
import com.cvte.tv.api.functions.ITVApiSystemCec;
import java.util.List;

/* JADX INFO: loaded from: classes.dex */
public class TVApiSystemCecService extends ITVApiSystemCecAidl.Stub {
    public static final String TVAPI_NOFOUND_ERROR = "TV Api not found";

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecReset(EnumResetLevel enumResetLevel) throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecReset(enumResetLevel);
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecSetEnable(boolean z) throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecSetEnable(z);
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecIsEnabled() throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecIsEnabled();
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecSetAutoPowerConnectedDeviceEnable(boolean z) throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecSetAutoPowerConnectedDeviceEnable(z);
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecIsAutoPowerConnectedDeviceEnabled() throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecIsAutoPowerConnectedDeviceEnabled();
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecSetAllowDeviceCtrlTVPowerOnEnable(boolean z) throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecSetAllowDeviceCtrlTVPowerOnEnable(z);
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecIsAllowDeviceCtrlTVPowerOnEnabled() throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecIsAllowDeviceCtrlTVPowerOnEnabled();
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecConnectSlaveDevice(EntityCecDevice entityCecDevice) throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecConnectSlaveDevice(entityCecDevice);
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public List<EntityCecDevice> eventSystemCecGetSlaveDevicesList() throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecGetSlaveDevicesList();
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecSetKeyEvent(int i) throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecSetKeyEvent(i);
    }

    @Override // com.cvte.tv.api.aidl.ITVApiSystemCecAidl
    public boolean eventSystemCecStandbyOrOpenDev(int i, int i2) throws RemoteException {
        ITVApiSystemCec iTVApiSystemCec = (ITVApiSystemCec) MiddleWareApi.getInstance().getTvApi(ITVApiSystemCec.class);
        if (iTVApiSystemCec == null) {
            throw new RemoteException("TV Api not found");
        }
        return iTVApiSystemCec.eventSystemCecStandbyOrOpenDev(i, i2);
    }
}
