Fix two Eclipse warnings

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1647325 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Dominik Stadler 2014-12-22 14:56:47 +00:00
parent 83f5683c50
commit 7ee9ce8388
2 changed files with 3 additions and 3 deletions

View File

@ -22,6 +22,7 @@ import java.util.Iterator;
import org.apache.poi.hssf.model.InternalWorkbook;
import org.apache.poi.hssf.record.LabelSSTRecord;
import org.apache.poi.hssf.record.common.UnicodeString;
import org.apache.poi.hssf.record.common.UnicodeString.FormatRun;
import org.apache.poi.ss.usermodel.Font;
import org.apache.poi.ss.usermodel.RichTextString;
/**
@ -147,10 +148,10 @@ public final class HSSFRichTextString implements Comparable<HSSFRichTextString>,
//Need to clear the current formatting between the startIndex and endIndex
_string = cloneStringIfRequired();
Iterator formatting = _string.formatIterator();
Iterator<FormatRun> formatting = _string.formatIterator();
if (formatting != null) {
while (formatting.hasNext()) {
UnicodeString.FormatRun r = (UnicodeString.FormatRun)formatting.next();
UnicodeString.FormatRun r = formatting.next();
if ((r.getCharacterPos() >= startIndex) && (r.getCharacterPos() < endIndex))
formatting.remove();
}

View File

@ -18,7 +18,6 @@
package org.apache.poi.xssf.usermodel;
import java.util.Iterator;
import java.util.Map;
import java.util.TreeMap;
import org.apache.poi.ss.SpreadsheetVersion;