package com.hi.music.player.ui.activity.viewmodel;

import androidx.lifecycle.LiveData;
import androidx.lifecycle.MutableLiveData;
import androidx.lifecycle.ViewModel;

import com.hi.music.player.api.RequestListener;
import com.hi.music.player.helper.CommonUtils;
import com.hi.music.player.javabean.CustomerUrlInfo;
import com.hi.music.player.javabean.response.ResponsePlayListInfo;
import com.hi.music.player.javabean.response.ResponsePlayUrl;
import com.hi.music.player.javabean.response.child.ResponseSingle;
import com.hi.music.player.media3.MyMediaControllerManager;
import com.hi.music.player.network.JsonHelper;
import com.hi.music.player.network.RetrofitManager;

import org.json.JSONObject;

import java.util.List;

import okhttp3.ResponseBody;

public class VMApplication extends ViewModel {


    private MutableLiveData<List<ResponsePlayListInfo>> _playList = new MutableLiveData<List<ResponsePlayListInfo>>();
    public LiveData<List<ResponsePlayListInfo>> playList = _playList;


    private MutableLiveData<Integer> _playStatus = new MutableLiveData<Integer>();
    public LiveData<Integer>  playStatus = _playStatus;


    /**
     * 重置播放列表
     * @param list
     */
    public void reSetPlayList(List<ResponsePlayListInfo> list) {
        _playList.setValue(list);
    }

    public void setPlayStatus(int status) {
        _playStatus.setValue(status);
    }


}
