valchkou / cassandra-driver-mapping

JPA addon for DataStax Java Driver for Cassandra
58 stars 24 forks source link

Is @MappedSuperClass supported? #59

Open wilsondy opened 9 years ago

wilsondy commented 9 years ago

I tried it and it doesn't appear to work? Was hoping to create a superclass that i have common fields in with several subclasses.

valchkou commented 9 years ago

Hi, jpa annotation @MappedSuperclass is not supported.. But you can have a SuperClass with mapping annotations and extend your Entity from it.

wilsondy commented 9 years ago

hmmm, it appears EntityTypeParser.parsePropoertyLevelMetadata is using Class.getDeclaredFields which would not surface properties in the parent class under any circumstances.

What is your appetite is for PRs?

valchkou commented 9 years ago

Let me check if I can do something simple to enable it. I will respond shortly

modikartik commented 9 years ago

Hi, I used this library and it solved lots of my issues. Great work and very useful.

I also faced the same issue of super class so I vote in for that :-)