Browse Source

New class org.apache.poi.hssf.record.RecordFormatException, which DDF uses instead of the HSSF version, and the HSSF version inherits from

git-svn-id: https://svn.apache.org/repos/asf/poi/branches/ooxml@678374 13f79535-47bb-0310-9956-ffa450edef68
tags/REL_3_5_BETA2
Nick Burch 16 years ago
parent
commit
8eb4ea33e6

+ 1
- 0
src/documentation/content/xdocs/changes.xml View File

@@ -37,6 +37,7 @@

<!-- Don't forget to update status.xml too! -->
<release version="3.5.1-beta2" date="2008-??-??">
<action dev="POI-DEVELOPERS" type="add">New class org.apache.poi.hssf.record.RecordFormatException, which DDF uses instead of the HSSF version, and the HSSF version inherits from</action>
<action dev="POI-DEVELOPERS" type="add">45431 - Partial support for .xlm files. Not quite enough for excel to load them though</action>
<action dev="POI-DEVELOPERS" type="fix">45430 - Correct named range sheet reporting when no local sheet id is given in the xml</action>
</release>

+ 11
- 0
src/documentation/content/xdocs/spreadsheet/converting.xml View File

@@ -48,6 +48,17 @@
<em>org.apache.poi.ss.usermodel.Row.MissingCellPolicy</em>
</p>
</section>
<section><title>DDF and org.apache.poi.hssf.record.RecordFormatException</title>
<p>Previously, record level errors within DDF would throw an
exception from the hssf class heirachy. Now, record level errors
within DDF will throw a more general RecordFormatException,
<em>org.apache.poi.util.RecordFormatException</em></p>
<p>In addition, org.apache.poi.hssf.record.RecordFormatException
has been changed to inherit from the new
<em>org.apache.poi.util.RecordFormatException</em>, so you may
wish to change catches of the hssf version to the new util version.
</p>
</section>
</section>
<section><title>Converting existing HSSF Usermodel code to SS Usermodel (for XSSF and HSSF)</title>


+ 1
- 0
src/documentation/content/xdocs/status.xml View File

@@ -34,6 +34,7 @@
<!-- Don't forget to update changes.xml too! -->
<changes>
<release version="3.5.1-beta2" date="2008-??-??">
<action dev="POI-DEVELOPERS" type="add">New class org.apache.poi.hssf.record.RecordFormatException, which DDF uses instead of the HSSF version, and the HSSF version inherits from</action>
<action dev="POI-DEVELOPERS" type="add">45431 - Partial support for .xlm files. Not quite enough for excel to load them though</action>
<action dev="POI-DEVELOPERS" type="fix">45430 - Correct named range sheet reporting when no local sheet id is given in the xml</action>
</release>

+ 1
- 1
src/java/org/apache/poi/ddf/DefaultEscherRecordFactory.java View File

@@ -18,7 +18,7 @@
package org.apache.poi.ddf;

import org.apache.poi.hssf.record.RecordFormatException;
import org.apache.poi.util.RecordFormatException;

import java.lang.reflect.Constructor;
import java.util.HashMap;

+ 1
- 1
src/java/org/apache/poi/ddf/EscherBlipWMFRecord.java View File

@@ -18,9 +18,9 @@
package org.apache.poi.ddf;

import org.apache.poi.hssf.record.RecordFormatException;
import org.apache.poi.util.HexDump;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.util.RecordFormatException;

import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;

+ 1
- 1
src/java/org/apache/poi/ddf/EscherDggRecord.java View File

@@ -18,9 +18,9 @@
package org.apache.poi.ddf;

import org.apache.poi.hssf.record.RecordFormatException;
import org.apache.poi.util.HexDump;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.util.RecordFormatException;

import java.util.*;


+ 1
- 1
src/java/org/apache/poi/ddf/EscherSpgrRecord.java View File

@@ -20,7 +20,7 @@ package org.apache.poi.ddf;

import org.apache.poi.util.HexDump;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.hssf.record.RecordFormatException;
import org.apache.poi.util.RecordFormatException;

/**
* The spgr record defines information about a shape group. Groups in escher

+ 1
- 1
src/java/org/apache/poi/ddf/EscherSplitMenuColorsRecord.java View File

@@ -20,7 +20,7 @@ package org.apache.poi.ddf;

import org.apache.poi.util.HexDump;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.hssf.record.RecordFormatException;
import org.apache.poi.util.RecordFormatException;

/**
* A list of the most recently used colours for the drawings contained in

+ 1
- 1
src/java/org/apache/poi/ddf/EscherTextboxRecord.java View File

@@ -18,9 +18,9 @@
package org.apache.poi.ddf;

import org.apache.poi.hssf.record.RecordFormatException;
import org.apache.poi.util.HexDump;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.util.RecordFormatException;

/**
* Holds data from the parent application. Most commonly used to store

+ 1
- 1
src/java/org/apache/poi/hssf/record/RecordFormatException.java View File

@@ -25,7 +25,7 @@ package org.apache.poi.hssf.record;
*/

public class RecordFormatException
extends RuntimeException
extends org.apache.poi.util.RecordFormatException
{
public RecordFormatException(String exception)
{

+ 42
- 0
src/java/org/apache/poi/util/RecordFormatException.java View File

@@ -0,0 +1,42 @@

/* ====================================================================
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
==================================================================== */

package org.apache.poi.util;

/**
* A common exception thrown by our binary format parsers
* (especially HSSF and DDF), when they hit invalid
* format or data when processing a record.
*/
public class RecordFormatException
extends RuntimeException
{
public RecordFormatException(String exception)
{
super(exception);
}
public RecordFormatException(String exception, Throwable thr) {
super(exception, thr);
}
public RecordFormatException(Throwable thr) {
super(thr);
}
}

Loading…
Cancel
Save