// add enum literals, if appropriate
if ( type.getKind() == TypeDeclaration.Kind.ENUM ) {
for ( EnumLiteralDescr lit : ((EnumDeclarationDescr) typeDescr).getLiterals() ) {
((EnumClassDefinition) def).addLiteral(
new EnumLiteralDefinition( lit.getName(), lit.getConstructorArgs() )
);
}
}
// fields definitions are created. will be used by subclasses, if any.