简体   繁体   English

java.lang.NoSuchMethodError:com.google.gdata.client.media.MediaService.insert(MediaService.java:318)

[英]java.lang.NoSuchMethodError:com.google.gdata.client.media.MediaService.insert(MediaService.java:318)

DocsService client= new DocsService ("idea");
 client.useSsl ();
  client.setOAuthCredentials (oauthParameters, new OAuthHmacSha1Signer ());
    DocumentListEntry newEntry= new com.google.gdata.data.docs.SpreadsheetEntry ();
        newEntry.setTitle (new PlainTextConstruct ("GIdeaDB"));
        DocumentListEntry insertedEntry= client.insert (new URL (
       "https://docs.google.com/feeds/default/private/full/?xoauth_requestor_id="+                        userEmail), newEntry);

but i got NoSuchMethodException in client.insert (new URL ( "https://docs.google.com/feeds/default/private/full/?xoauth_requestor_id="+ userEmail), newEntry); 但我在client.insert中获得了NoSuchMethodException(新网址(“https://docs.google.com/feeds/default/private/full/?xoauth_requestor_id="+ userEmail),newEntry);

what i do please help me.... 我做了什么请帮助我....

NoSuchMethodError通常意味着您使用不同版本的库来编译代码而不是用于运行它的代码。

One of the insert methods take three parameters and one takes two. 其中一个插入方法有三个参数,一个需要两个参数。 Neither of these methods match what you ate passing in. Which version of the library are you compiling with and which version are you running with? 这两种方法都不符合您传入的内容。您编译的库版本和运行的版本是什么? As I said in my comment it is likely to be a version mismatch if it compiles but does not run. 正如我在评论中所说,如果它编译但不运行,则可能是版本不匹配。

See https://developers.google.com/gdata/javadoc/com/google/gdata/client/docs/DocsService 请参阅https://developers.google.com/gdata/javadoc/com/google/gdata/client/docs/DocsService

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 谷歌驱动器dredit错误java.lang.NoSuchMethodError:com.google.api.client.http.HttpRequestFactory.buildRequest - google drive dredit error java.lang.NoSuchMethodError: com.google.api.client.http.HttpRequestFactory.buildRequest java.lang.NoSuchMethodError:com.google.api.client.http.HttpRequest.setParser - java.lang.NoSuchMethodError: com.google.api.client.http.HttpRequest.setParser java.lang.NoSuchMethodError: 'boolean com.google.api.client.http.HttpTransport.isMtls() - java.lang.NoSuchMethodError: 'boolean com.google.api.client.http.HttpTransport.isMtls() java.lang.NoSuchMethodError: com.google.api.client.http.HttpTransport.isMtls()Z - java.lang.NoSuchMethodError: com.google.api.client.http.HttpTransport.isMtls()Z java.lang.NoSuchMethodError:com.google.common.base.Preconditions - java.lang.NoSuchMethodError: com.google.common.base.Preconditions java.lang.NoSuchMethodError:com.google.api.client.http.javanet.NetHttpTransport。<init> (Lcom/google/api/client/http/javanet/ConnectionFactory; - java.lang.NoSuchMethodError: com.google.api.client.http.javanet.NetHttpTransport.<init>(Lcom/google/api/client/http/javanet/ConnectionFactory; java.lang.NoSuchMethodError: - java.lang.NoSuchMethodError: java.lang.NoSuchMethodError:带有Selenium和Java的com.google.common.collect.ImmutableSet.of([Ljava / lang / Object;) - java.lang.NoSuchMethodError: com.google.common.collect.ImmutableSet.of([Ljava/lang/Object;) with Selenium and Java java.lang.NoSuchMethodError - java.lang.NoSuchMethodError App Engine Java部署错误:java.lang.NoSuchMethodError:com.google.common.reflect.TypeToken.isSubtypeOf - App Engine Java Deployment Error: java.lang.NoSuchMethodError: com.google.common.reflect.TypeToken.isSubtypeOf
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM