Generator wont generate java source for empty extensions
This commit is contained in:
parent
13a9134e4b
commit
239e01f6bb
|
@ -87,7 +87,7 @@ public class GeneratorProcessorFactory implements AnnotationProcessorFactory, Ro
|
||||||
if (first_round) {
|
if (first_round) {
|
||||||
env.addListener(this);
|
env.addListener(this);
|
||||||
return new GeneratorProcessor(env);
|
return new GeneratorProcessor(env);
|
||||||
}
|
} else
|
||||||
return AnnotationProcessors.NO_OP;
|
return AnnotationProcessors.NO_OP;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -231,10 +231,10 @@ public class GeneratorVisitor extends SimpleDeclarationVisitor {
|
||||||
|
|
||||||
public void visitInterfaceDeclaration(InterfaceDeclaration d) {
|
public void visitInterfaceDeclaration(InterfaceDeclaration d) {
|
||||||
try {
|
try {
|
||||||
|
if (d.getMethods().size() > 0 || d.getFields().size() > 0)
|
||||||
generateJavaSource(d);
|
generateJavaSource(d);
|
||||||
if (d.getMethods().size() > 0) {
|
if (d.getMethods().size() > 0)
|
||||||
generateNativeSource(d);
|
generateNativeSource(d);
|
||||||
}
|
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue