MemberExpressionNode getterSelector =
AbstractSyntaxTreeUtil.generateGetterSelector(nodeFactory, className, false);
String qualifiedBackingPropertyName = accessorInfo.getQualifiedBackingPropertyName().intern();
IdentifierNode identifer =
AbstractSyntaxTreeUtil.generateIdentifier(nodeFactory, qualifiedBackingPropertyName, false);
GetExpressionNode getExpression = nodeFactory.getExpression(identifer);
MemberExpressionNode memberExpression = nodeFactory.memberExpression(getterSelector, getExpression);
ListNode returnList = nodeFactory.list(null, memberExpression);
returnStatement = nodeFactory.returnStatement(returnList);
}
else
{
// Equivalent AS:
//
// return this.${entry.qualifiedBackingPropertyName};
ThisExpressionNode thisExpression = nodeFactory.thisExpression(0);
String qualifiedBackingPropertyName = accessorInfo.getQualifiedBackingPropertyName().intern();
IdentifierNode identifer =
AbstractSyntaxTreeUtil.generateIdentifier(nodeFactory, qualifiedBackingPropertyName, false);
GetExpressionNode getExpression = nodeFactory.getExpression(identifer);
MemberExpressionNode memberExpression = nodeFactory.memberExpression(thisExpression, getExpression);
ListNode returnList = nodeFactory.list(null, memberExpression);
returnStatement = nodeFactory.returnStatement(returnList);
}