if (constant.getName().equals(name.getSymbolName())) {
throw new IllegalArgumentException("Enum constant '"
+ name.getSymbolName() + "' already exists");
}
}
final EnumConstantDeclaration newEntry = new EnumConstantDeclaration(
name.getSymbolName());
constants.add(constants.size(), newEntry);
}