ext.appendToken(TokenBuilder.newSpace());
ext.addChildWithTokens(iface);
}
public void removeSuperInterface(String interfaceName) {
LinkedListTree impls = ASTUtils.findChildByType(ast, AS3Parser.EXTENDS);
int count = 0;
for (ASTIterator i=new ASTIterator(impls); i.hasNext(); ) {
LinkedListTree iface = i.next();
String name = ASTUtils.identText(iface);
if (name.equals(interfaceName)) {
if (i.hasNext()) {
ASTUtils.removeTrailingWhitespaceAndComma(iface.getStopToken());
} else if (count == 0) {
// no interfaces left, so remove the
// 'implements' clause completely,
ast.deleteChild(ast.getIndexOfChild(impls));
break;