Skip to content

Code generator: Include fields from multiple level parent classes #391

@superdaminou

Description

@superdaminou

Describe the bug
Assuming a inheritance like: C >(inherit) B > A.
Assuming that A as an attribute foo and a @MappedSuperclass .
Assuming that B as an attribute bar and a @MappedSuperclass
Assuming that C is an entity

When using the metamodel for C i should have access to foo.
Following #328 i correctly have access to C$.bar but not C$.foo

Expected behavior

Metamodel should have access fields from parents on multiple level.

Actual behavior

Metamodel have access only from the fields of direct parents

How To Reproduce
Having three class

@MappedSuperclass public class A { var foo; }

@MappedSuperclass public class B extends A { var bar; }

@Entity public class C extends B{}

Build tool
e.g. Maven 3.8.7

JPAStreamer version
e.g. JPAStreamer 3.0.3

JPA Provider
e.g. Hibernate 6.2.9.Final

Java Version
e.g. Java 21.0

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions