Set<Annotation> annotations = ProposalCalculatorUtil.findAnnotations("PathVariable", varDecl);
SimpleName varDeclName = varDecl.getName();
String varName = varDeclName.getFullyQualifiedName();
String pathVariableName = varName;
StringLiteral pathVariableLiteral = null;
for (Annotation annotation : annotations) {
if (annotation instanceof SingleMemberAnnotation) {
Expression value = ((SingleMemberAnnotation) annotation).getValue();
if (value instanceof StringLiteral) {
pathVariableLiteral = ((StringLiteral) value);
pathVariableName = pathVariableLiteral.getLiteralValue();
break;
}
}
}