Methods Summary |
---|
public java.lang.Object | clone()
LabelRecord rec = new LabelRecord();
rec.field_1_row = field_1_row;
rec.field_2_column = field_2_column;
rec.field_3_xf_index = field_3_xf_index;
rec.field_4_string_len = field_4_string_len;
rec.field_5_unicode_flag = field_5_unicode_flag;
rec.field_6_value = field_6_value;
return rec;
|
protected void | fillFields(org.apache.poi.hssf.record.RecordInputStream in)called by the constructor, should set class level fields. Should throw
runtime exception for bad/icomplete data.
//field_1_row = LittleEndian.getShort(data, 0 + offset);
field_1_row = in.readUShort();
field_2_column = in.readShort();
field_3_xf_index = in.readShort();
field_4_string_len = in.readShort();
field_5_unicode_flag = in.readByte();
if (field_4_string_len > 0) {
if (isUnCompressedUnicode()) {
field_6_value = in.readUnicodeLEString(field_4_string_len);
} else {
field_6_value = in.readCompressedUnicode(field_4_string_len);
}
} else field_6_value = null;
|
public short | getColumn()
return field_2_column;
|
public int | getRow()
return field_1_row;
|
public short | getSid()
return sid;
|
public short | getStringLength()get the number of characters this string contains
return field_4_string_len;
|
public java.lang.String | getValue()get the value
return field_6_value;
|
public short | getXFIndex()
return field_3_xf_index;
|
public boolean | isAfter(org.apache.poi.hssf.record.CellValueRecordInterface i)
if (this.getRow() < i.getRow())
{
return false;
}
if ((this.getRow() == i.getRow())
&& (this.getColumn() < i.getColumn()))
{
return false;
}
if ((this.getRow() == i.getRow())
&& (this.getColumn() == i.getColumn()))
{
return false;
}
return true;
|
public boolean | isBefore(org.apache.poi.hssf.record.CellValueRecordInterface i)
if (this.getRow() > i.getRow())
{
return false;
}
if ((this.getRow() == i.getRow())
&& (this.getColumn() > i.getColumn()))
{
return false;
}
if ((this.getRow() == i.getRow())
&& (this.getColumn() == i.getColumn()))
{
return false;
}
return true;
|
public boolean | isEqual(org.apache.poi.hssf.record.CellValueRecordInterface i)
return ((this.getRow() == i.getRow())
&& (this.getColumn() == i.getColumn()));
|
public boolean | isInValueSection()
return true;
|
public boolean | isUnCompressedUnicode()is this uncompressed unicode (16bit)? Or just 8-bit compressed?
return (field_5_unicode_flag == 1);
|
public boolean | isValue()
return true;
|
public int | serialize(int offset, byte[] data)THROWS A RUNTIME EXCEPTION.. USE LABELSSTRecords. YOU HAVE NO REASON to use LABELRecord!!
throw new RecordFormatException(
"Label Records are supported READ ONLY...convert to LabelSST");
|
public void | setColumn(short col)NO-OP!
|
public void | setRow(int row)NO-OP!
|
public void | setXFIndex(short xf)no op!
|
public java.lang.String | toString()
StringBuffer buffer = new StringBuffer();
buffer.append("[LABEL]\n");
buffer.append(" .row = ")
.append(Integer.toHexString(getRow())).append("\n");
buffer.append(" .column = ")
.append(Integer.toHexString(getColumn())).append("\n");
buffer.append(" .xfindex = ")
.append(Integer.toHexString(getXFIndex())).append("\n");
buffer.append(" .string_len = ")
.append(Integer.toHexString(field_4_string_len)).append("\n");
buffer.append(" .unicode_flag = ")
.append(Integer.toHexString(field_5_unicode_flag)).append("\n");
buffer.append(" .value = ")
.append(getValue()).append("\n");
buffer.append("[/LABEL]\n");
return buffer.toString();
|
protected void | validateSid(short id)called by constructor, should throw runtime exception in the event of a
record passed with a differing ID.
if (id != sid)
{
throw new RecordFormatException("Not a valid LabelRecord");
}
|