while (hasMoreLines(false)) {
line = nextLine();
try {
String plotName = (String) getTokenValue(line[0], false, false);
PlotInterface plot = importerUser.getPlot(plotName);
if (plot == null) {
errorHandler.showError("Error Importing Plots",
"The plot \"" + plotName + "\" does not exist.",
false);
// gobble up remaining lines of this section
while (hasMoreLines(false)) { } // NOPMD empty while loop OK
return;
} else {
int numPens = importIntro(plot);
importPens(plot, numPens);
importPoints(plot);
}
plot.makeDirty();
} catch (ClassCastException e) {
throw new AbortingImportException
(ImportError.ILLEGAL_CLASS_CAST_ERROR, "");
}
}