Top Fields Constructors Methods
org.apache.poi.hssf.record.aggregates

public final Class MergedCellsTable

extends RecordAggregate
Class Inheritance
Imports
java.util.ArrayList, .List, org.apache.poi.hssf.model.RecordStream, org.apache.poi.hssf.record.MergeCellsRecord, org.apache.poi.ss.util.CellRangeAddress, .CellRangeAddressList

Field Summary

Modifier and TypeField and Description
private final List<CellRangeAddress>
private static final int

Constructor Summary

AccessConstructor and Description
public
MergedCellsTable()

Creates an empty aggregate

Method Summary

Modifier and TypeMethod and Description
public void
addArea(int rowFrom, int colFrom, int rowTo, int colTo)

private void
public void
private void
checkIndex(int index)

public CellRangeAddress
get(int index)

public int
public int
getRecordSize()

Overrides org.apache.poi.hssf.record.aggregates.RecordAggregate.getRecordSize.

gives the current serialized size of the record.

public void
read(RecordStream rs)

reads zero or more consecutive MergeCellsRecords

public void
remove(int index)

public void
visitContainedRecords(RecordAggregate.RecordVisitor
The visitor to use for callbacks while walking this object
rv
)

Implements abstract org.apache.poi.hssf.record.aggregates.RecordAggregate.visitContainedRecords.

Visit each of the atomic BIFF records contained in this RecordAggregate in the order that they should be written to file.

Inherited from org.apache.poi.hssf.record.aggregates.RecordAggregate:
serialize

Field Detail

_mergedRegionsback to summary
private final List<CellRangeAddress> _mergedRegions
MAX_MERGED_REGIONSback to summary
private static final int MAX_MERGED_REGIONS

Constructor Detail

MergedCellsTableback to summary
public MergedCellsTable()

Creates an empty aggregate

Method Detail

addAreaback to summary
public void addArea(int rowFrom, int colFrom, int rowTo, int colTo)
addMergeCellsRecordback to summary
private void addMergeCellsRecord(MergeCellsRecord mcr)
addRecordsback to summary
public void addRecords(MergeCellsRecord[] mcrs)
checkIndexback to summary
private void checkIndex(int index)
getback to summary
public CellRangeAddress get(int index)
getNumberOfMergedRegionsback to summary
public int getNumberOfMergedRegions()
getRecordSizeback to summary
public int getRecordSize()

Overrides org.apache.poi.hssf.record.aggregates.RecordAggregate.getRecordSize.

Doc from org.apache.poi.hssf.record.RecordBase.getRecordSize.

gives the current serialized size of the record. Should include the sid and reclength (4 bytes).

Returns:int

the record size

Annotations
@Override
readback to summary
public void read(RecordStream rs)

reads zero or more consecutive MergeCellsRecords

removeback to summary
public void remove(int index)
visitContainedRecordsback to summary
public void visitContainedRecords(RecordAggregate.RecordVisitor rv)

Implements abstract org.apache.poi.hssf.record.aggregates.RecordAggregate.visitContainedRecords.

Doc from org.apache.poi.hssf.record.aggregates.RecordAggregate.visitContainedRecords.

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

Parameters
rv:RecordAggregate.RecordVisitor

The visitor to use for callbacks while walking this object

Annotations
@Override