in src/main/java/com/amazonaws/eclipse/simpleworkflow/asynchrony/annotationprocessor/ActivitiesValidator.java [59:80]
public Boolean visitExecutable(ExecutableElement e, ProcessingEnvironment p) {
TypeMirror returnType = e.getReturnType();
if (!ProcessorUtils.isVoidType(returnType) && ProcessorUtils.isPromiseType(returnType)) {
reportError(p, "Activity methods are not allowed to have Promise return type.", e);
}
for (VariableElement parameter: e.getParameters()) {
TypeMirror parameterType = parameter.asType();
if (ProcessorUtils.isPromiseType(parameterType)) {
reportError(p, "Activity methods are not allowed to have Promise parameter type.", parameter);
}
}
if ((version == null || version.isEmpty()) && (parentVersion == null || parentVersion.isEmpty())) {
Activity activityAnnotation = e.getAnnotation(Activity.class);
if (activityAnnotation == null || activityAnnotation.name().isEmpty()) {
reportError(p, "Activity version not specified.", e);
}
}
return super.visitExecutable(e, p);
}