I want to retrive the read only data from youtube using gData Java client but when I am trying to create the object of YouTubeService class it is throwing No Such Method Exception. Not able to find the resaon behind it.
YouTubeService service = new YouTubeService(clientID);
Exception is
java.lang.NoSuchMethodError:
com.google.gdata.data.ExtensionProfile.declareAdditionalNamespace(Lcom/google/gdata/util/common/xml/XmlWriter$Namespace;)
You most likely have compiled a class against a different version of the class that is missing a method, than the one you are using when running it.
Make sure you have the right version.
Look at the stack trace … If the exception appears when calling a method on an object in a library, you are most likely using separate versions of the library when compiling and running.
Make sure the class files that you are actually running are updated when you compile.
If the exception appears when calling a method on objects instantiated by classes you made, then your build process seems to be faulty.