我的本地磁盘中有一个视频,我想通过我的应用程序将其上传到 youtube。你能给我遵循同样的指导方针吗?请给我执行该操作的步骤或代码或链接。提前致谢。
在提出解决方案后,我尝试使用:gdata.youtube.com/feeds/api/users/users/uploads(用户作为用户名),但我收到 IOException.ie 与服务通信时出现问题。
java.net.SocketException: Connection reset
java.net.SocketInputStream.read(SocketInputStream.java:189)
at java.net.SocketInputStream.read(SocketInputStream.java:121)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:235)
at java.io.BufferedInputStream.read1(BufferedInputStream.java:275)
at java.io.BufferedInputStream.read(BufferedInputStream.java:334)
at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:641)
at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:589)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1319)
at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:468)
at com.google.gdata.client.http.HttpGDataRequest.checkResponse(HttpGDataRequest.java:490)
at com.google.gdata.client.http.HttpGDataRequest.execute(HttpGDataRequest.java:470)
at com.google.gdata.client.http.GoogleGDataRequest.execute(GoogleGDataRequest.java:534)
at com.google.gdata.client.media.MediaService.insert(MediaService.java:353)
at ytupload.YouTubeWriteClient.uploadVideo(YouTubeWriteClient.java:508)
at ytupload.YouTubeWriteClient.main(YouTubeWriteClient.java:828)
请帮忙...