Top Description Fields Constructors Methods
org.apache.poi.ss.formula.ptg

public abstract Class RefPtgBase

extends OperandPtg
Class Inheritance
Known Direct Subclasses
org.apache.poi.ss.formula.ptg.Ref2DPtgBase, org.apache.poi.ss.formula.ptg.Ref3DPtg, org.apache.poi.ss.formula.ptg.Ref3DPxg
Imports
java.util.Map, java.util.function.Supplier, org.apache.poi.ss.util.CellReference, org.apache.poi.util.BitField, .BitFieldFactory, .GenericRecordUtil, .LittleEndianInput, .LittleEndianOutput

ReferencePtgBase - handles references (such as A1, A2, IA4)

Field Summary

Modifier and TypeField and Description
private static final BitField
private static final BitField
column

YK: subclasses of RefPtgBase are used by the FormulaParser and FormulaEvaluator across HSSF and XSSF.

private int
field_1_row

The row index - zero based unsigned 16 bit value

private int
field_2_col

Field 2 - lower 8 bits is the zero based unsigned byte column index - bit 16 - isRowRelative - bit 15 - isColumnRelative

private static final BitField

Constructor Summary

AccessConstructor and Description
protected
protected
protected

Method Summary

Modifier and TypeMethod and Description
protected String
public final int
public final byte
public Map<String, Supplier<?>>
public final int

Returns:

the row number as an int
getRow
()

public final boolean
public final boolean
protected final void
public final void
setColRelative(boolean rel)

public final void
setColumn(int col)

public final void
setRow(int rowIndex)

public final void
setRowRelative(boolean rel)

protected final void
Inherited from org.apache.poi.ss.formula.ptg.OperandPtg:
copyisBaseToken

Field Detail

colRelativeback to summary
private static final BitField colRelative
columnback to summary
private static final BitField column

YK: subclasses of RefPtgBase are used by the FormulaParser and FormulaEvaluator across HSSF and XSSF. The bit mask should accommodate the maximum number of available columns, i.e. 0x3FFF.

See Also
org.apache.poi.ss.SpreadsheetVersion
field_1_rowback to summary
private int field_1_row

The row index - zero based unsigned 16 bit value

field_2_colback to summary
private int field_2_col

Field 2 - lower 8 bits is the zero based unsigned byte column index - bit 16 - isRowRelative - bit 15 - isColumnRelative

rowRelativeback to summary
private static final BitField rowRelative

Constructor Detail

RefPtgBaseback to summary
protected RefPtgBase()
RefPtgBaseback to summary
protected RefPtgBase(RefPtgBase other)
RefPtgBaseback to summary
protected RefPtgBase(CellReference c)

Method Detail

formatReferenceAsStringback to summary
protected String formatReferenceAsString()
getColumnback to summary
public final int getColumn()
getDefaultOperandClassback to summary
public final byte getDefaultOperandClass()

Implements abstract org.apache.poi.ss.formula.ptg.Ptg.getDefaultOperandClass.

Annotations
@Override
getGenericPropertiesback to summary
public Map<String, Supplier<?>> getGenericProperties()

Implements org.apache.poi.common.usermodel.GenericRecord.getGenericProperties.

Annotations
@Override
getRowback to summary
public final int getRow()
Returns:int

the row number as an int

isColRelativeback to summary
public final boolean isColRelative()
isRowRelativeback to summary
public final boolean isRowRelative()
readCoordinatesback to summary
protected final void readCoordinates(LittleEndianInput in)
setColRelativeback to summary
public final void setColRelative(boolean rel)
setColumnback to summary
public final void setColumn(int col)
setRowback to summary
public final void setRow(int rowIndex)
setRowRelativeback to summary
public final void setRowRelative(boolean rel)
writeCoordinatesback to summary
protected final void writeCoordinates(LittleEndianOutput out)