Class CFRecordsAggregate

  • public final class CFRecordsAggregate
    extends RecordAggregate

    CFRecordsAggregate - aggregates Conditional Formatting records CFHeaderRecord and number of up CFRuleRecord records together to simplify access to them.

    Note that Excel versions before 2007 can only cope with a maximum of 3 Conditional Formatting rules per sheet. Excel 2007 or newer can cope with unlimited numbers, as can Apache OpenOffice. This is an Excel limitation, not a file format one.

    • Method Detail

      • createCFAggregate

        public static CFRecordsAggregate createCFAggregate​(RecordStream rs)
        Create CFRecordsAggregate from a list of CF Records
        rs - - the stream to read from
        CFRecordsAggregate object
      • cloneCFAggregate

        public CFRecordsAggregate cloneCFAggregate()
        Create a deep clone of the record
      • getHeader

        public CFHeaderBase getHeader()
        the header. Never null.
      • getRule

        public CFRuleBase getRule​(int idx)
      • setRule

        public void setRule​(int idx,
                            CFRuleBase r)
      • getNumberOfRules

        public int getNumberOfRules()
      • toString

        public java.lang.String toString()
        String representation of CFRecordsAggregate
        toString in class java.lang.Object
      • visitContainedRecords

        public void visitContainedRecords​(RecordAggregate.RecordVisitor rv)
        Description copied from class: RecordAggregate
        Visit each of the atomic BIFF records contained in this RecordAggregate in the order that they should be written to file. Implementors may or may not return the actual Records being used to manage POI's internal implementation. Callers should not assume either way, and therefore only attempt to modify those Records after cloning
        Specified by:
        visitContainedRecords in class RecordAggregate
      • updateFormulasAfterCellShift

        public boolean updateFormulasAfterCellShift​(FormulaShifter shifter,
                                                    int currentExternSheetIx)
        false if this whole CFHeaderRecord / CFRuleRecords should be deleted