This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 26322

Summary: bug in XmiContext.findProxy(ModelElement)
Product: java Reporter: _ hkrug <hkrug>
Component: UnsupportedAssignee: Daniel Prusa <dprusa>
Status: RESOLVED FIXED    
Severity: blocker    
Priority: P4    
Version: 3.x   
Hardware: PC   
OS: Linux   
Issue Type: DEFECT Exception Reporter:

Description _ hkrug 2002-08-06 21:00:05 UTC
The following piece of code in
XmiContext.findProxy(ModelElement) is buggy:

  MofPackage mofPackage = (MofPackage)
path.removeLast ();
  ....
       MofPackage meta = (MofPackage)
ref.refMetaObject ();
       if (meta instanceof MofPackage) {

Actually it must be checked if mofPackage is a
parent of meta. IMHO the last line must be
replaced in the following way:

       if (
meta.allSupertypes().contains(mofPackage) ) {
Comment 1 Daniel Prusa 2002-08-19 16:06:55 UTC
Fixed.