org.eclipse.jdt.core.dom.Block block = ast.newBlock();
/*
* define the return value
*/
SimpleName returnValueName = ast.newSimpleName("newGXTBean");
VariableDeclarationFragment fragment = ast.newVariableDeclarationFragment();
fragment.setName(returnValueName);
ClassInstanceCreation newClassInstance = ast.newClassInstanceCreation();
newClassInstance.setType((Type)returnType.copySubtree(ast, returnType));
fragment.setInitializer(newClassInstance);
VariableDeclarationStatement returnValue = ast.newVariableDeclarationStatement(fragment);
returnValue.setType((Type)returnType.copySubtree(ast, returnType));
block.statements().add(returnValue);
/*
* call each get method in the original and pass the result to the new set method