java.lang.IllegalStateException what does it mean?

烂漫一生 提交于 2019-11-28 16:33:54
Reno

If you see this state diagram (taken from https://developer.android.com/reference/android/media/MediaPlayer.html#StateDiagram):

You will realize that you should call reset() to get it back to the idle state. Only then can you call setDataSource()

Amit

Android docs say about IllegalStateException:

Thrown when an action is attempted at a time when the VM is not in the correct state.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!