我得到了java.lang.IllegalStateException:
java.lang.IllegalStateException:setRequestProperty调用方法
后,无法在连接建立后设置请求属性url.openConnection();
这是我正在尝试的:
URL url = new URL("https://49.205.102.182:7070/obsplatform/api/v1/mediadevices/545b801ce37e69cc");
urlConnection = (HttpsURLConnection) url
.openConnection();
urlConnection.setRequestProperty("Content-Type","application/json");
Run Code Online (Sandbox Code Playgroud)
有什么建议吗?提前致谢.
android ×1