Abstract records should never be directly referenced; fail as early as possible and explain what's going on.
This commit is contained in:
@@ -90,6 +90,9 @@ public class DepotMarshaller<T extends PersistentRecord>
|
||||
{
|
||||
_pClass = pClass;
|
||||
|
||||
Preconditions.checkArgument(!java.lang.reflect.Modifier.isAbstract(pClass.getModifiers()),
|
||||
"Can't handle reference to abstract record: " + pClass.getName());
|
||||
|
||||
Entity entity = pClass.getAnnotation(Entity.class);
|
||||
|
||||
// see if this is a computed entity
|
||||
|
||||
Reference in New Issue
Block a user