Javadocs, and more record names

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1690490 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Nick Burch 2015-07-12 17:31:54 +00:00
parent 57f4733ba4
commit 8c1cb7e48a
4 changed files with 20 additions and 14 deletions

View File

@ -23,9 +23,9 @@ import org.apache.poi.ss.util.CellRangeAddressList;
import org.apache.poi.util.LittleEndianOutput; import org.apache.poi.util.LittleEndianOutput;
/** /**
* Conditional Formatting Header record CFHEADER (0x01B0) * Conditional Formatting Header record CFHEADER (0x01B0).
* * Used to describe a {@link CFRuleRecord}.
* @author Dmitriy Kumshayev * @see CFHeader12Record
*/ */
public final class CFHeaderRecord extends StandardRecord { public final class CFHeaderRecord extends StandardRecord {
public static final short sid = 0x01B0; public static final short sid = 0x01B0;

View File

@ -35,7 +35,7 @@ import org.apache.poi.util.LittleEndianOutput;
* Conditional Formatting Rule Record (0x01B1). * Conditional Formatting Rule Record (0x01B1).
* *
* <p>This is for the older-style Excel conditional formattings, * <p>This is for the older-style Excel conditional formattings,
* new-style (Excel 2007+) also make use of {@link CF12RuleRecord} * new-style (Excel 2007+) also make use of {@link CFRule12Record}
* and {@link CFExRuleRecord} for their rules. * and {@link CFExRuleRecord} for their rules.
*/ */
public final class CFRuleRecord extends StandardRecord { public final class CFRuleRecord extends StandardRecord {

View File

@ -34,8 +34,11 @@ import org.apache.poi.util.POILogger;
* up with a {@link FeatHdrRecord}. * up with a {@link FeatHdrRecord}.
*/ */
public final class FeatRecord extends StandardRecord { public final class FeatRecord extends StandardRecord {
private static POILogger logger = POILogFactory.getLogger(FeatRecord.class); private static POILogger logger = POILogFactory.getLogger(FeatRecord.class);
public final static short sid = 0x0868; public final static short sid = 0x0868;
// SIDs from newer versions
public final static short v11_sid = 0x0872;
public final static short v12_sid = 0x0878;
private FtrHeader futureHeader; private FtrHeader futureHeader;

View File

@ -179,8 +179,10 @@ public final class UnknownRecord extends StandardRecord {
case SHEETPROTECTION_0867: return "SHEETPROTECTION"; case SHEETPROTECTION_0867: return "SHEETPROTECTION";
case 0x086B: return "DATALABEXTCONTENTS"; case 0x086B: return "DATALABEXTCONTENTS";
case 0x086C: return "CELLWATCH"; case 0x086C: return "CELLWATCH";
case FeatRecord.v11_sid: return "SHARED FEATURE v11";
case 0x0874: return "DROPDOWNOBJIDS"; case 0x0874: return "DROPDOWNOBJIDS";
case 0x0876: return "DCONN"; case 0x0876: return "DCONN";
case FeatRecord.v12_sid: return "SHARED FEATURE v12";
case 0x087B: return "CFEX"; case 0x087B: return "CFEX";
case 0x087C: return "XFCRC"; case 0x087C: return "XFCRC";
case 0x087D: return "XFEXT"; case 0x087D: return "XFEXT";
@ -194,15 +196,21 @@ public final class UnknownRecord extends StandardRecord {
case 0x089A: return "MTRSETTINGS"; case 0x089A: return "MTRSETTINGS";
case 0x089B: return "COMPRESSPICTURES"; case 0x089B: return "COMPRESSPICTURES";
case HEADER_FOOTER_089C: return "HEADERFOOTER"; case HEADER_FOOTER_089C: return "HEADERFOOTER";
case 0x089D: return "CRTLAYOUT12";
case 0x089E: return "CRTMLFRT";
case 0x089F: return "CRTMLFRTCONTINUE";
case 0x08A1: return "SHAPEPROPSSTREAM"; case 0x08A1: return "SHAPEPROPSSTREAM";
case 0x08A3: return "FORCEFULLCALCULATION"; case 0x08A3: return "FORCEFULLCALCULATION";
case 0x08A4: return "SHAPEPROPSSTREAM"; case 0x08A4: return "SHAPEPROPSSTREAM";
case 0x08A5: return "TEXTPROPSSTREAM"; case 0x08A5: return "TEXTPROPSSTREAM";
case 0x08A6: return "RICHTEXTSTREAM"; case 0x08A6: return "RICHTEXTSTREAM";
case 0x08A7: return "CRTLAYOUT12A";
case 0x08C8: return "PLV{Mac Excel}"; case 0x08C8: return "PLV{Mac Excel}";
case 0x1001: return "UNITS";
case 0x1006: return "CHARTDATAFORMAT";
case 0x1007: return "CHARTLINEFORMAT";
} }
if (isObservedButUnknown(sid)) { if (isObservedButUnknown(sid)) {
return "UNKNOWN-" + Integer.toHexString(sid).toUpperCase(); return "UNKNOWN-" + Integer.toHexString(sid).toUpperCase();
@ -215,6 +223,7 @@ public final class UnknownRecord extends StandardRecord {
* @return <code>true</code> if the unknown record id has been observed in POI unit tests * @return <code>true</code> if the unknown record id has been observed in POI unit tests
*/ */
private static boolean isObservedButUnknown(int sid) { private static boolean isObservedButUnknown(int sid) {
// TODO Look up more of these in the latest [MS-XLS] doc and move to getBiffName
switch (sid) { switch (sid) {
case 0x0033: case 0x0033:
// contains 2 bytes of data: 0x0001 or 0x0003 // contains 2 bytes of data: 0x0001 or 0x0003
@ -227,13 +236,7 @@ public final class UnknownRecord extends StandardRecord {
// Written by Excel 2007 // Written by Excel 2007
// rawData is multiple of 12 bytes long // rawData is multiple of 12 bytes long
// appears after last cell value record and before WINDOW2 or drawing records // appears after last cell value record and before WINDOW2 or drawing records
case 0x089D:
case 0x089E:
case 0x08A7:
case 0x1001:
case 0x1006:
case 0x1007:
case 0x1009: case 0x1009:
case 0x100A: case 0x100A:
case 0x100B: case 0x100B: