Re: java.lang.NoSuchMethodError

Martin Matula <[email protected]> Wed, 14 Jan 2004 20:55:25 +0100
Newsgroups gmane.comp.java.netbeans.modules.mdr.devel
Message-ID <[email protected]>
It seems that the classes you have on the classpath do not contain the 
method. Are you sure you have correctly build the new generated 
interfaces and replaced the old ones on your application's classpath?
Martin

Fu,Bin wrote:

> Hi,
>  
> I added the metamodel "diagraminterchange" into my metamodel. With MDR 
> explorer, it is no problem to get JMI interfaces from the package 
> "diagraminterchange". But when I read it into MDR programmatically, the 
> method "getDiagramInterchange()" in the top level package Java file 
> cannot be found. See following exception message:
>  
> /java.lang.NoSuchMethodError: 
> library.LibraryPackage.getDiagramInterchange()Llibrary/diagraminterchange/DiagramInterchangePackage;/
>  
> But the method "getDiagramInterchange()" exists in the java file of top 
> level package generated by MDR explorer. Please have a look at java file 
> "library" of top level package as following:
>  
> /package library;/
> /public interface LibraryPackage extends javax.jmi.reflect.RefPackage {
>     public library.infrastructurelibrary.InfrastructureLibraryPackage 
> getInfrastructureLibrary();
>     public library.uml2.Uml2Package getUml2();
>     public library.diagraminterchange.DiagramInterchangePackage 
> getDiagramInterchange();
> }
> /
>  
> I guess the problem is in my current model, or what else could be the 
> reason? If you need, I can send you my current metamodel or create an issue.
>  
> Thanks & Regards
>  
> Fu, Bin
>  
>