From: Nick Burch Date: Sat, 19 Jul 2014 19:00:09 +0000 (+0000) Subject: Fix Generics warnings X-Git-Tag: REL_3_11_BETA1~88 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=7a372e6f361d6e27f98c16a6c8debf7976e886f0;p=poi.git Fix Generics warnings git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1611944 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/java/org/apache/poi/hssf/eventusermodel/EventWorkbookBuilder.java b/src/java/org/apache/poi/hssf/eventusermodel/EventWorkbookBuilder.java index c8c2491f3c..c6036d6582 100644 --- a/src/java/org/apache/poi/hssf/eventusermodel/EventWorkbookBuilder.java +++ b/src/java/org/apache/poi/hssf/eventusermodel/EventWorkbookBuilder.java @@ -65,7 +65,7 @@ public class EventWorkbookBuilder { */ public static InternalWorkbook createStubWorkbook(ExternSheetRecord[] externs, BoundSheetRecord[] bounds, SSTRecord sst) { - List wbRecords = new ArrayList(); + List wbRecords = new ArrayList(); // Core Workbook records go first if(bounds != null) { @@ -114,8 +114,8 @@ public class EventWorkbookBuilder { */ public static class SheetRecordCollectingListener implements HSSFListener { private HSSFListener childListener; - private List boundSheetRecords = new ArrayList(); - private List externSheetRecords = new ArrayList(); + private List boundSheetRecords = new ArrayList(); + private List externSheetRecords = new ArrayList(); private SSTRecord sstRecord = null; public SheetRecordCollectingListener(HSSFListener childListener) { @@ -124,12 +124,12 @@ public class EventWorkbookBuilder { public BoundSheetRecord[] getBoundSheetRecords() { - return (BoundSheetRecord[])boundSheetRecords.toArray( + return boundSheetRecords.toArray( new BoundSheetRecord[boundSheetRecords.size()] ); } public ExternSheetRecord[] getExternSheetRecords() { - return (ExternSheetRecord[])externSheetRecords.toArray( + return externSheetRecords.toArray( new ExternSheetRecord[externSheetRecords.size()] ); } @@ -166,10 +166,10 @@ public class EventWorkbookBuilder { */ public void processRecordInternally(Record record) { if(record instanceof BoundSheetRecord) { - boundSheetRecords.add(record); + boundSheetRecords.add((BoundSheetRecord)record); } else if(record instanceof ExternSheetRecord) { - externSheetRecords.add(record); + externSheetRecords.add((ExternSheetRecord)record); } else if(record instanceof SSTRecord) { sstRecord = (SSTRecord)record;