Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 340898

Summary: Problem when super class has generics
Product: z_Archived Reporter: Blaise Doughan <blaise.doughan>
Component: EclipselinkAssignee: Nobody - feel free to take it <nobody>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: eclipselink.oxm-inbox, i82much
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
MOXy - Test Cases
none
MOXy - Fix none

Description Blaise Doughan CLA 2011-03-24 14:51:19 EDT
Given the following model:

import java.util.List;

public class AbstractClassWithGenerics<T> {

    private List<T> a;

    public List<T> getA() {
        return a;
    }

    public void setA(List<T> a) {
        this.a = a;
    }

}

and

public class ConcreteClassWithGenerics extends AbstractClassWithGenerics<String> {

}

An exception is thrown when trying to create a JAXBContext on the subclass.
Comment 1 Blaise Doughan CLA 2011-03-24 14:54:35 EDT
Created attachment 191855 [details]
MOXy - Test Cases
Comment 2 Blaise Doughan CLA 2011-03-24 14:58:30 EDT
Created attachment 191856 [details]
MOXy - Fix
Comment 3 Blaise Doughan CLA 2011-03-25 09:28:15 EDT
Fix checked into trunk at rev:  9171

Code reviewed by:  Matt MacIvor

Fix Description:
In Property guard against there being an ActualTypeArguments list of size 0.
Comment 4 Blaise Doughan CLA 2011-06-01 12:53:06 EDT
*** Bug 347958 has been marked as a duplicate of this bug. ***
Comment 5 Eclipse Webmaster CLA 2022-06-09 10:32:43 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink