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

public final Class FormatRecord

extends StandardRecord
Class Inheritance
Imports
java.util.Arrays, .Map, java.util.function.Supplier, org.apache.logging.log4j.LogManager, .Logger, org.apache.poi.hssf.model.InternalWorkbook, org.apache.poi.util.GenericRecordUtil, .LittleEndianConsts, .LittleEndianOutput, .StringUtil

Describes a number format -- those goofy strings like $(#,###)

Field Summary

Modifier and TypeField and Description
private final int
private final boolean
private final String
private static final Logger
public static final short

Constructor Summary

AccessConstructor and Description
private
public
FormatRecord(int indexCode, String fs)

public

Method Summary

Modifier and TypeMethod and Description
public FormatRecord
protected int
public String

Returns:

the format string
getFormatString
()

get the format string

public Map<String, Supplier<?>>
public HSSFRecordTypes
public int

Returns:

the format index code
getIndexCode
()

get the format index code (for built in formats)

public short
getSid()

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

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

private static String
readStringCommon(RecordInputStream ris, int requestedLength, boolean pIsCompressedEncoding)

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.

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

Field Detail

field_1_index_codeback to summary
private final int field_1_index_code
field_3_hasMultibyteback to summary
private final boolean field_3_hasMultibyte
field_4_formatstringback to summary
private final String field_4_formatstring
LOGback to summary
private static final Logger LOG
sidback to summary
public static final short sid

Constructor Detail

FormatRecordback to summary
private FormatRecord(FormatRecord other)
FormatRecordback to summary
public FormatRecord(int indexCode, String fs)
FormatRecordback to summary
public FormatRecord(RecordInputStream in)

Method Detail

copyback to summary
public FormatRecord copy()

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

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

Returns:FormatRecord

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.

getFormatStringback to summary
public String getFormatString()

get the format string

Returns:String

the format string

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
getIndexCodeback to summary
public int getIndexCode()

get the format index code (for built in formats)

Returns:int

the format index code

See Also
InternalWorkbook
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

readStringCommonback to summary
private static String readStringCommon(RecordInputStream ris, int requestedLength, boolean pIsCompressedEncoding)
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