use of com.querydsl.codegen.Supertype in project querydsl by querydsl.
the class ExtendedTypeFactory method createEntityType.
@Nullable
private EntityType createEntityType(TypeMirror typeMirror, List<String> key, boolean deep) {
entityTypeCache.put(key, null);
Type value = visitor.visit(typeMirror, deep);
if (value != null) {
EntityType entityType = null;
if (value instanceof EntityType) {
entityType = (EntityType) value;
} else {
entityType = new EntityType(value, variableNameFunction);
typeMappings.register(entityType, queryTypeFactory.create(entityType));
}
entityTypeCache.put(key, entityType);
if (deep) {
for (Type superType : getSupertypes(typeMirror, deep)) {
entityType.addSupertype(new Supertype(superType));
}
}
return entityType;
} else {
return null;
}
}
Aggregations