]> source.dussan.org Git - poi.git/commitdiff
Javadocs, and more record names
authorNick Burch <nick@apache.org>
Sun, 12 Jul 2015 17:31:54 +0000 (17:31 +0000)
committerNick Burch <nick@apache.org>
Sun, 12 Jul 2015 17:31:54 +0000 (17:31 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1690490 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/poi/hssf/record/CFHeaderRecord.java
src/java/org/apache/poi/hssf/record/CFRuleRecord.java
src/java/org/apache/poi/hssf/record/FeatRecord.java
src/java/org/apache/poi/hssf/record/UnknownRecord.java

index eb17ee275814c23b704a3b285c18d45e88ac7592..bfdd4b05793c240fd8b189960b7db81c3585cb5f 100644 (file)
@@ -23,9 +23,9 @@ import org.apache.poi.ss.util.CellRangeAddressList;
 import org.apache.poi.util.LittleEndianOutput;
 
 /**
- * Conditional Formatting Header record CFHEADER (0x01B0)
- * 
- * @author Dmitriy Kumshayev
+ * Conditional Formatting Header record CFHEADER (0x01B0).
+ * Used to describe a {@link CFRuleRecord}.
+ * @see CFHeader12Record
  */
 public final class CFHeaderRecord extends StandardRecord {
        public static final short sid = 0x01B0;
index d2673685518bf659dd9af8ba0e42cc3fc23b4350..fa0a4295a673c67f89d86abb819a785c69abfac6 100644 (file)
@@ -35,7 +35,7 @@ import org.apache.poi.util.LittleEndianOutput;
  * Conditional Formatting Rule Record (0x01B1). 
  * 
  * <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.
  */
 public final class CFRuleRecord extends StandardRecord {
index 572d6959d9582e2cb89f88ebfc0781a3b4c03989..fd583a3d780b0f07ae8fdd6ce002d35cd935e521 100644 (file)
@@ -34,8 +34,11 @@ import org.apache.poi.util.POILogger;
  *  up with a {@link FeatHdrRecord}.
  */
 public final class FeatRecord extends StandardRecord  {
-       private static POILogger logger = POILogFactory.getLogger(FeatRecord.class);
-       public final static short sid = 0x0868;
+    private static POILogger logger = POILogFactory.getLogger(FeatRecord.class);
+    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;
        
index 6b46247e23e1a80aece90dfa387874a0f7f9aa67..f87953aba3d18a1c6b369534360b3c9652b1c9f4 100644 (file)
@@ -179,8 +179,10 @@ public final class UnknownRecord extends StandardRecord {
             case SHEETPROTECTION_0867: return "SHEETPROTECTION";
             case 0x086B: return "DATALABEXTCONTENTS";
             case 0x086C: return "CELLWATCH";
+            case FeatRecord.v11_sid: return "SHARED FEATURE v11";
             case 0x0874: return "DROPDOWNOBJIDS";
             case 0x0876: return "DCONN";
+            case FeatRecord.v12_sid: return "SHARED FEATURE v12";
             case 0x087B: return "CFEX";
             case 0x087C: return "XFCRC";
             case 0x087D: return "XFEXT";
@@ -194,15 +196,21 @@ public final class UnknownRecord extends StandardRecord {
             case 0x089A: return "MTRSETTINGS";
             case 0x089B: return "COMPRESSPICTURES";
             case HEADER_FOOTER_089C: return "HEADERFOOTER";
+            case 0x089D: return "CRTLAYOUT12";
+            case 0x089E: return "CRTMLFRT";
+            case 0x089F: return "CRTMLFRTCONTINUE";
             case 0x08A1: return "SHAPEPROPSSTREAM";
             case 0x08A3: return "FORCEFULLCALCULATION";
             case 0x08A4: return "SHAPEPROPSSTREAM";
             case 0x08A5: return "TEXTPROPSSTREAM";
             case 0x08A6: return "RICHTEXTSTREAM";
+            case 0x08A7: return "CRTLAYOUT12A";
 
             case 0x08C8: return "PLV{Mac Excel}";
-
-
+            
+            case 0x1001: return "UNITS";
+            case 0x1006: return "CHARTDATAFORMAT";
+            case 0x1007: return "CHARTLINEFORMAT";
         }
         if (isObservedButUnknown(sid)) {
             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
      */
     private static boolean isObservedButUnknown(int sid) {
+        // TODO Look up more of these in the latest [MS-XLS] doc and move to getBiffName
         switch (sid) {
             case 0x0033:
                 // contains 2 bytes of data: 0x0001 or 0x0003
@@ -227,13 +236,7 @@ public final class UnknownRecord extends StandardRecord {
                 // Written by Excel 2007
                 // rawData is multiple of 12 bytes long
                 // 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 0x100A:
             case 0x100B: