Top Description Fields Constructors Methods
org.apache.poi.hssf.record.chart

public final Class LegendRecord

extends StandardRecord
Class Inheritance
Static Imports
org.apache.poi.util.GenericRecordUtil.getBitsAsString, .GenericRecordUtil.getEnumBitsAsString

Defines a legend for a chart.

Field Summary

Modifier and TypeField and Description
private static final BitField
private static final BitField
private static final BitField
private static final BitField
private static final BitField
private int
private int
private int
private int
private byte
private byte
private short
public static final short
public static final byte
public static final byte
public static final byte
public static final byte
public static final byte
public static final byte
public static final byte
public static final byte
public static final byte
private static final BitField

Constructor Summary

AccessConstructor and Description
public
public
public

Method Summary

Modifier and TypeMethod and Description
public LegendRecord
protected int
public Map<String, Supplier<?>>
public HSSFRecordTypes
public short
getOptions()

Get the options field for the Legend record.

public short
getSid()

Implements abstract org.apache.poi.hssf.record.Record.getSid.

return the non static version of the id for this record.

public byte

Returns:

One of SPACING_CLOSE SPACING_MEDIUM SPACING_OPEN
getSpacing
()

Get the spacing field for the Legend record.

public byte

Returns:

One of TYPE_BOTTOM TYPE_CORNER TYPE_TOP TYPE_RIGHT TYPE_LEFT TYPE_UNDOCKED
getType
()

Get the type field for the Legend record.

public int
getXAxisUpperLeft()

Get the x axis upper left field for the Legend record.

public int
getXSize()

Get the x size field for the Legend record.

public int
getYAxisUpperLeft()

Get the y axis upper left field for the Legend record.

public int
getYSize()

Get the y size field for the Legend record.

public boolean

Returns:

the auto position field value.
isAutoPosition
()

automatic positioning (1=docked)

public boolean

Returns:

the auto series field value.
isAutoSeries
()

excel 5 only (true)

public boolean

Returns:

the auto x positioning field value.
isAutoXPositioning
()

position of legend on the x axis is automatic

public boolean

Returns:

the auto y positioning field value.
isAutoYPositioning
()

position of legend on the y axis is automatic

public boolean

Returns:

the data table field value.
isDataTable
()

1 if chart contains data table

public boolean

Returns:

the vertical field value.
isVertical
()

vertical or horizontal legend (1 or 0 respectively).

public void
serialize(LittleEndianOutput
the output object
out
)

Implements abstract org.apache.poi.hssf.record.StandardRecord.serialize.

Write the data content of this BIFF record.

public void
setAutoPosition(boolean value)

Sets the auto position field value.

public void
setAutoSeries(boolean value)

Sets the auto series field value.

public void
setAutoXPositioning(boolean value)

Sets the auto x positioning field value.

public void
setAutoYPositioning(boolean value)

Sets the auto y positioning field value.

public void
setDataTable(boolean value)

Sets the data table field value.

public void
setOptions(short field_7_options)

Set the options field for the Legend record.

public void
setSpacing(byte
One of SPACING_CLOSE SPACING_MEDIUM SPACING_OPEN
field_6_spacing
)

Set the spacing field for the Legend record.

public void
setType(byte
One of TYPE_BOTTOM TYPE_CORNER TYPE_TOP TYPE_RIGHT TYPE_LEFT TYPE_UNDOCKED
field_5_type
)

Set the type field for the Legend record.

public void
setVertical(boolean value)

Sets the vertical field value.

public void
setXAxisUpperLeft(int field_1_xAxisUpperLeft)

Set the x axis upper left field for the Legend record.

public void
setXSize(int field_3_xSize)

Set the x size field for the Legend record.

public void
setYAxisUpperLeft(int field_2_yAxisUpperLeft)

Set the y axis upper left field for the Legend record.

public void
setYSize(int field_4_ySize)

Set the y size field for the Legend record.

Inherited from org.apache.poi.hssf.record.StandardRecord:
getRecordSizeserialize

Field Detail

autoPositionback to summary
private static final BitField autoPosition
autoSeriesback to summary
private static final BitField autoSeries
autoXPositioningback to summary
private static final BitField autoXPositioning
autoYPositioningback to summary
private static final BitField autoYPositioning
dataTableback to summary
private static final BitField dataTable
field_1_xAxisUpperLeftback to summary
private int field_1_xAxisUpperLeft
field_2_yAxisUpperLeftback to summary
private int field_2_yAxisUpperLeft
field_3_xSizeback to summary
private int field_3_xSize
field_4_ySizeback to summary
private int field_4_ySize
field_5_typeback to summary
private byte field_5_type
field_6_spacingback to summary
private byte field_6_spacing
field_7_optionsback to summary
private short field_7_options
sidback to summary
public static final short sid
SPACING_CLOSEback to summary
public static final byte SPACING_CLOSE
SPACING_MEDIUMback to summary
public static final byte SPACING_MEDIUM
SPACING_OPENback to summary
public static final byte SPACING_OPEN
TYPE_BOTTOMback to summary
public static final byte TYPE_BOTTOM
TYPE_CORNERback to summary
public static final byte TYPE_CORNER
TYPE_LEFTback to summary
public static final byte TYPE_LEFT
TYPE_RIGHTback to summary
public static final byte TYPE_RIGHT
TYPE_TOPback to summary
public static final byte TYPE_TOP
TYPE_UNDOCKEDback to summary
public static final byte TYPE_UNDOCKED
verticalback to summary
private static final BitField vertical

Constructor Detail

LegendRecordback to summary
public LegendRecord()
LegendRecordback to summary
public LegendRecord(LegendRecord other)
LegendRecordback to summary
public LegendRecord(RecordInputStream in)

Method Detail

copyback to summary
public LegendRecord copy()

Implements abstract org.apache.poi.hssf.record.StandardRecord.copy.

Implements org.apache.poi.common.Duplicatable.copy.

Returns:LegendRecord

Doc from org.apache.poi.common.Duplicatable.copy.

a deep copy of the implementing class / instance

Annotations
@Override
getDataSizeback to summary
protected int getDataSize()

Implements abstract org.apache.poi.hssf.record.StandardRecord.getDataSize.

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

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

Annotations
@Override
getGenericRecordTypeback to summary
public HSSFRecordTypes getGenericRecordType()

Overrides default org.apache.poi.common.usermodel.GenericRecord.getGenericRecordType.

Implements abstract org.apache.poi.hssf.record.Record.getGenericRecordType.

Annotations
@Override
getOptionsback to summary
public short getOptions()

Get the options field for the Legend record.

getSidback to summary
public short getSid()

Implements abstract org.apache.poi.hssf.record.Record.getSid.

Doc from org.apache.poi.hssf.record.Record.getSid.

return the non static version of the id for this record.

Returns:short

he id for this record

getSpacingback to summary
public byte getSpacing()

Get the spacing field for the Legend record.

Returns:byte

One of SPACING_CLOSE SPACING_MEDIUM SPACING_OPEN

getTypeback to summary
public byte getType()

Get the type field for the Legend record.

Returns:byte

One of TYPE_BOTTOM TYPE_CORNER TYPE_TOP TYPE_RIGHT TYPE_LEFT TYPE_UNDOCKED

getXAxisUpperLeftback to summary
public int getXAxisUpperLeft()

Get the x axis upper left field for the Legend record.

getXSizeback to summary
public int getXSize()

Get the x size field for the Legend record.

getYAxisUpperLeftback to summary
public int getYAxisUpperLeft()

Get the y axis upper left field for the Legend record.

getYSizeback to summary
public int getYSize()

Get the y size field for the Legend record.

isAutoPositionback to summary
public boolean isAutoPosition()

automatic positioning (1=docked)

Returns:boolean

the auto position field value.

isAutoSeriesback to summary
public boolean isAutoSeries()

excel 5 only (true)

Returns:boolean

the auto series field value.

isAutoXPositioningback to summary
public boolean isAutoXPositioning()

position of legend on the x axis is automatic

Returns:boolean

the auto x positioning field value.

isAutoYPositioningback to summary
public boolean isAutoYPositioning()

position of legend on the y axis is automatic

Returns:boolean

the auto y positioning field value.

isDataTableback to summary
public boolean isDataTable()

1 if chart contains data table

Returns:boolean

the data table field value.

isVerticalback to summary
public boolean isVertical()

vertical or horizontal legend (1 or 0 respectively). Always 0 if not automatic.

Returns:boolean

the vertical field value.

serializeback to summary
public void serialize(LittleEndianOutput out)

Implements abstract org.apache.poi.hssf.record.StandardRecord.serialize.

Doc from org.apache.poi.hssf.record.StandardRecord.serialize.

Write the data content of this BIFF record. The 'ushort sid' and 'ushort size' header fields have already been written by the superclass.

The number of bytes written must equal the record size reported by org.apache.poi.hssf.record.Record#getRecordSize()} minus four ( record header consisting of a 'ushort sid' and 'ushort reclength' has already been written by their superclass).

Parameters
out:LittleEndianOutput

the output object

setAutoPositionback to summary
public void setAutoPosition(boolean value)

Sets the auto position field value. automatic positioning (1=docked)

setAutoSeriesback to summary
public void setAutoSeries(boolean value)

Sets the auto series field value. excel 5 only (true)

setAutoXPositioningback to summary
public void setAutoXPositioning(boolean value)

Sets the auto x positioning field value. position of legend on the x axis is automatic

setAutoYPositioningback to summary
public void setAutoYPositioning(boolean value)

Sets the auto y positioning field value. position of legend on the y axis is automatic

setDataTableback to summary
public void setDataTable(boolean value)

Sets the data table field value. 1 if chart contains data table

setOptionsback to summary
public void setOptions(short field_7_options)

Set the options field for the Legend record.

setSpacingback to summary
public void setSpacing(byte field_6_spacing)

Set the spacing field for the Legend record.

Parameters
field_6_spacing:byte

One of SPACING_CLOSE SPACING_MEDIUM SPACING_OPEN

setTypeback to summary
public void setType(byte field_5_type)

Set the type field for the Legend record.

Parameters
field_5_type:byte

One of TYPE_BOTTOM TYPE_CORNER TYPE_TOP TYPE_RIGHT TYPE_LEFT TYPE_UNDOCKED

setVerticalback to summary
public void setVertical(boolean value)

Sets the vertical field value. vertical or horizontal legend (1 or 0 respectively). Always 0 if not automatic.

setXAxisUpperLeftback to summary
public void setXAxisUpperLeft(int field_1_xAxisUpperLeft)

Set the x axis upper left field for the Legend record.

setXSizeback to summary
public void setXSize(int field_3_xSize)

Set the x size field for the Legend record.

setYAxisUpperLeftback to summary
public void setYAxisUpperLeft(int field_2_yAxisUpperLeft)

Set the y axis upper left field for the Legend record.

setYSizeback to summary
public void setYSize(int field_4_ySize)

Set the y size field for the Legend record.