Fix Generics warnings

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1611944 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Nick Burch 2014-07-19 19:00:09 +00:00
parent 31cd7f7e57
commit 7a372e6f36
1 changed files with 7 additions and 7 deletions

View File

@ -65,7 +65,7 @@ public class EventWorkbookBuilder {
*/ */
public static InternalWorkbook createStubWorkbook(ExternSheetRecord[] externs, public static InternalWorkbook createStubWorkbook(ExternSheetRecord[] externs,
BoundSheetRecord[] bounds, SSTRecord sst) { BoundSheetRecord[] bounds, SSTRecord sst) {
List wbRecords = new ArrayList(); List<Record> wbRecords = new ArrayList<Record>();
// Core Workbook records go first // Core Workbook records go first
if(bounds != null) { if(bounds != null) {
@ -114,8 +114,8 @@ public class EventWorkbookBuilder {
*/ */
public static class SheetRecordCollectingListener implements HSSFListener { public static class SheetRecordCollectingListener implements HSSFListener {
private HSSFListener childListener; private HSSFListener childListener;
private List boundSheetRecords = new ArrayList(); private List<BoundSheetRecord> boundSheetRecords = new ArrayList<BoundSheetRecord>();
private List externSheetRecords = new ArrayList(); private List<ExternSheetRecord> externSheetRecords = new ArrayList<ExternSheetRecord>();
private SSTRecord sstRecord = null; private SSTRecord sstRecord = null;
public SheetRecordCollectingListener(HSSFListener childListener) { public SheetRecordCollectingListener(HSSFListener childListener) {
@ -124,12 +124,12 @@ public class EventWorkbookBuilder {
public BoundSheetRecord[] getBoundSheetRecords() { public BoundSheetRecord[] getBoundSheetRecords() {
return (BoundSheetRecord[])boundSheetRecords.toArray( return boundSheetRecords.toArray(
new BoundSheetRecord[boundSheetRecords.size()] new BoundSheetRecord[boundSheetRecords.size()]
); );
} }
public ExternSheetRecord[] getExternSheetRecords() { public ExternSheetRecord[] getExternSheetRecords() {
return (ExternSheetRecord[])externSheetRecords.toArray( return externSheetRecords.toArray(
new ExternSheetRecord[externSheetRecords.size()] new ExternSheetRecord[externSheetRecords.size()]
); );
} }
@ -166,10 +166,10 @@ public class EventWorkbookBuilder {
*/ */
public void processRecordInternally(Record record) { public void processRecordInternally(Record record) {
if(record instanceof BoundSheetRecord) { if(record instanceof BoundSheetRecord) {
boundSheetRecords.add(record); boundSheetRecords.add((BoundSheetRecord)record);
} }
else if(record instanceof ExternSheetRecord) { else if(record instanceof ExternSheetRecord) {
externSheetRecords.add(record); externSheetRecords.add((ExternSheetRecord)record);
} }
else if(record instanceof SSTRecord) { else if(record instanceof SSTRecord) {
sstRecord = (SSTRecord)record; sstRecord = (SSTRecord)record;