Skip to content

TopLevelEnumeration and eclipse generator merge, getting "No types defined in the file" #139

@dldeveloper21

Description

@dldeveloper21

I created a plugin which generates Enum files based on database tables using the method:

public List<GeneratedJavaFile> contextGenerateAdditionalJavaFiles( IntrospectedTable introspectedTable )

This plugin works perfectly for generating the Enums. However, when the Enums already exist and the eclipse generator tries to merge these files, I'm getting the error "No types defined in the file".

The error is coming from JavaFileMerger.getMergedSource(). It seems visitor.getTypeDeclaration() is returning null if it is an Enum. If I change these to be regular java classes, I don't get this error.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions