latest changes

git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@353519 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Said Ryan Ackley 2004-03-02 06:31:46 +00:00
parent d313836fb2
commit be07b1422a
9 changed files with 8966 additions and 438 deletions

View File

@ -1,398 +0,0 @@
/* ====================================================================
* The Apache Software License, Version 1.1
*
* Copyright (c) 2003 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
*
* 3. The end-user documentation included with the redistribution,
* if any, must include the following acknowledgment:
* "This product includes software developed by the
* Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowledgment may appear in the software itself,
* if and wherever such third-party acknowledgments normally appear.
*
* 4. The names "Apache" and "Apache Software Foundation" and
* "Apache POI" must not be used to endorse or promote products
* derived from this software without prior written permission. For
* written permission, please contact apache@apache.org.
*
* 5. Products derived from this software may not be called "Apache",
* "Apache POI", nor may "Apache" appear in their name, without
* prior written permission of the Apache Software Foundation.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* ====================================================================
*
* This software consists of voluntary contributions made by many
* individuals on behalf of the Apache Software Foundation. For more
* information on the Apache Software Foundation, please see
* <http://www.apache.org/>.
*/
package org.apache.poi.hwpf;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.hwpf.usermodel.SectionRange;
import org.apache.poi.hwpf.usermodel.CharacterRange;
import org.apache.poi.hwpf.usermodel.ParagraphRange;
import org.apache.poi.hwpf.usermodel.CharacterRun;
import org.apache.poi.hwpf.usermodel.Paragraph;
import org.apache.poi.hwpf.usermodel.Section;
import org.apache.poi.hwpf.model.hdftypes.PropertyNode;
import org.apache.poi.hwpf.model.hdftypes.StyleSheet;
import org.apache.poi.hwpf.model.hdftypes.StyleDescription;
import org.apache.poi.hwpf.model.hdftypes.CHPBinTable;
import org.apache.poi.hwpf.model.hdftypes.CHPX;
import org.apache.poi.hwpf.model.hdftypes.PAPX;
import org.apache.poi.hwpf.model.hdftypes.SEPX;
import org.apache.poi.hwpf.model.hdftypes.PAPBinTable;
import org.apache.poi.hwpf.model.hdftypes.SectionTable;
import org.apache.poi.hwpf.model.hdftypes.TextPieceTable;
import org.apache.poi.hwpf.model.hdftypes.TextPiece;
import org.apache.poi.hwpf.sprm.CharacterSprmUncompressor;
import org.apache.poi.hwpf.sprm.CharacterSprmCompressor;
import org.apache.poi.hwpf.sprm.SectionSprmUncompressor;
import org.apache.poi.hwpf.sprm.ParagraphSprmUncompressor;
import java.util.List;
import java.util.ArrayList;
import java.io.UnsupportedEncodingException;
import java.lang.ref.SoftReference;
public class Range
{
private int _start;
private int _end;
private HWPFDocument _doc;
boolean _sectionRangeFound;
private List _sections;
int _sectionStart;
int _sectionEnd;
boolean _parRangeFound;
private List _paragraphs;
int _parStart;
int _parEnd;
boolean _charRangeFound;
private List _characters;
int _charStart;
int _charEnd;
boolean _textRangeFound;
private List _text;
int _textStart;
int _textEnd;
protected Range(int start, int end, HWPFDocument doc)
{
_start = start;
_end = end;
_doc = doc;
_sections = _doc.getSectionTable().getSections();
_paragraphs = _doc.getParagraphTable().getParagraphs();
_characters = _doc.getCharacterTable().getTextRuns();
_text = _doc.getTextTable().getTextPieces();
}
protected Range(int start, int end, Range parent)
{
_start = start;
_end = end;
_doc = parent._doc;
_sections = parent._sections;
_paragraphs = parent._paragraphs;
_characters = parent._characters;
_text = parent._text;
}
public String text()
throws UnsupportedEncodingException
{
initText();
StringBuffer sb = new StringBuffer();
int size = _text.size();
for (int x = 0; x < size; x++)
{
TextPiece tp = (TextPiece)_text.get(x);
StringBuffer pieceSb = (StringBuffer)tp.getCacheContents();
if (pieceSb == null)
{
String encoding = "Cp1252";
if (tp.usesUnicode())
{
encoding = "UTF-16LE";
}
String str = new String(tp.getBuf(), encoding);
pieceSb = new StringBuffer(str);
tp.fillCache(pieceSb);
}
int startIndex = Math.max(0, (tp.getStart() - _start));
int endIndex = Math.min(tp.getEnd() - startIndex, _end - startIndex);
sb.append(pieceSb.toString().substring(startIndex, endIndex));
}
return sb.toString();
}
public int numSections()
{
initSections();
return _sections.size();
}
public int numParagraphs()
{
initParagraphs();
return _paragraphs.size();
}
public int numCharacterRuns()
{
initCharacterRuns();
return _characters.size();
}
public CharacterRange insertBefore(String text)
throws UnsupportedEncodingException
{
initAll();
TextPiece tp = (TextPiece)_text.get(_textStart);
StringBuffer sb = (StringBuffer)tp.getStringBuffer();
// Since this is the first item in our list, it is safe to assume that
// _start >= tp.getStart()
int insertIndex = _start - tp.getStart();
sb.insert(insertIndex, text);
int adjustedLength = _doc.getTextTable().adjustForInsert(_textStart, text.length());
_doc.getCharacterTable().adjustForInsert(_textStart, adjustedLength);
_doc.getParagraphTable().adjustForInsert(_textStart, adjustedLength);
_doc.getSectionTable().adjustForInsert(_textStart, adjustedLength);
return getCharacterRange(0);
}
public CharacterRange insertAfter(String text)
{
return null;
}
public CharacterRange insertBefore(String text, CharacterRun cr)
throws UnsupportedEncodingException
{
initAll();
PAPX papx = (PAPX)_paragraphs.get(_parStart);
short istd = papx.getIstd();
StyleSheet ss = _doc.getStyleSheet();
CharacterRun baseStyle = ss.getCharacterStyle(istd);
byte[] grpprl = CharacterSprmCompressor.compressCharacterProperty(cr, baseStyle);
_doc.getCharacterTable().insert(_charStart, _start, grpprl);
return insertBefore(text);
}
public CharacterRange insertAfter(String text, CharacterRun cr)
{
return null;
}
public ParagraphRange insertBefore(Paragraph paragraph)
{
return null;
}
public ParagraphRange insertAfter(Paragraph paragraph)
{
return null;
}
public CharacterRun getCharacterRun(int index)
{
initCharacterRuns();
CHPX chpx = (CHPX)_characters.get(index + _charStart);
CharacterRun chp = (CharacterRun)chpx.getCacheContents();
if (chp == null)
{
int[] point = findRange(_paragraphs, _parStart, chpx.getStart(),
chpx.getEnd());
List paragraphList = _paragraphs.subList(point[0], point[1]);
PAPX papx = (PAPX)paragraphList.get(0);
short istd = papx.getIstd();
StyleSheet sd = _doc.getStyleSheet();
CharacterRun baseStyle = sd.getCharacterStyle(istd);
chp = CharacterSprmUncompressor.uncompressCHP(baseStyle, chpx.getBuf(), 0);
chpx.fillCache(chp);
}
return chp;
}
public Section getSection(int index)
{
initSections();
SEPX sepx = (SEPX)_sections.get(index + _sectionStart);
Section sep = (Section)sepx.getCacheContents();
if (sep == null)
{
sep = SectionSprmUncompressor.uncompressSEP(new Section(), sepx.getBuf(), 0);
sepx.fillCache(sep);
}
return sep;
}
public Paragraph getParagraph(int index)
{
initParagraphs();
PAPX papx = (PAPX)_paragraphs.get(index + _parStart);
Paragraph pap = (Paragraph)papx.getCacheContents();
if (pap == null)
{
short istd = LittleEndian.getShort(papx.getBuf());
StyleSheet sd = _doc.getStyleSheet();
Paragraph baseStyle = sd.getParagraphStyle(istd);
pap = ParagraphSprmUncompressor.uncompressPAP(baseStyle, papx.getBuf(), 2);
papx.fillCache(pap);
}
return pap;
}
public SectionRange getSectionRange(int index)
{
initSections();
PropertyNode node = (PropertyNode)_sections.get(index + _sectionStart);
return new SectionRange(Math.max(_start, node.getStart()),
Math.min(_end, node.getEnd()), this);
}
public ParagraphRange getParagraphRange(int index)
{
initParagraphs();
PropertyNode node = (PropertyNode)_paragraphs.get(index + _parStart);
return new ParagraphRange(Math.max(_start, node.getStart()),
Math.min(_end, node.getEnd()),this);
}
public CharacterRange getCharacterRange(int index)
{
initCharacterRuns();
PropertyNode node = (PropertyNode)_characters.get(index + _charStart);
return new CharacterRange(Math.max(_start, node.getStart()),
Math.min(_end, node.getEnd()), this);
}
public SectionRange sections()
{
return new SectionRange(_start, _end, _doc);
}
public ParagraphRange paragraphs()
{
return new ParagraphRange(_start, _end, _doc);
}
public CharacterRange characterRuns()
{
return new CharacterRange(_start, _end, _doc);
}
private void initAll()
{
initText();
initCharacterRuns();
initParagraphs();
initSections();
}
private void initParagraphs()
{
if (!_parRangeFound)
{
int[] point = findRange(_paragraphs, _parStart, _start, _end);
_parStart = point[0];
_parEnd = point[1];
_parRangeFound = true;
}
}
private void initCharacterRuns()
{
if (!_charRangeFound)
{
int[] point = findRange(_characters, _charStart, _start, _end);
_charStart = point[0];
_charEnd = point[1];
_charRangeFound = true;
}
}
private void initText()
{
if (!_textRangeFound)
{
int[] point = findRange(_text, _textStart, _start, _end);
_textStart = point[0];
_textEnd = point[1];
_textRangeFound = true;
}
}
private void initSections()
{
if (!_sectionRangeFound)
{
int[] point = findRange(_sections, _sectionStart, _start, _end);
_sectionStart = point[0];
_sectionEnd = point[1];
_sectionRangeFound = true;
}
}
private int[] findRange(List rpl, int min, int start, int end)
{
int x = min;
PropertyNode node = (PropertyNode)rpl.get(x);
while(node.getStart() < start)
{
x++;
node = (PropertyNode)rpl.get(x);
}
int y = x;
node = (PropertyNode)rpl.get(y);
while(node.getEnd() > end)
{
y++;
node = (PropertyNode)rpl.get(y);
}
return new int[]{x, y + 1};
}
}

View File

@ -1,40 +0,0 @@
package org.apache.poi.hwpf.model;
import junit.framework.*;
import org.apache.poi.hwpf.*;
import org.apache.poi.hwpf.model.io.*;
import java.io.*;
import java.util.*;
public class TestListTables
extends HWPFTestCase
{
public TestListTables()
{
}
public void testReadWrite()
throws Exception
{
FileInformationBlock fib = _hWPFDocFixture._fib;
byte[] tableStream = _hWPFDocFixture._tableStream;
ListTables listTables = new ListTables(tableStream, fib.getFcPlcfLst(), fib.getFcPlfLfo());
HWPFFileSystem fileSys = new HWPFFileSystem();
HWPFOutputStream tableOut = fileSys.getStream("1Table");
listTables.writeListDataTo(tableOut);
int offset = tableOut.getOffset();
listTables.writeListOverridesTo(tableOut);
ListTables newTables = new ListTables(tableOut.toByteArray(), 0, offset);
assertEquals(listTables, newTables);
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,866 @@
/* ====================================================================
* The Apache Software License, Version 1.1
*
* Copyright (c) 2003 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
*
* 3. The end-user documentation included with the redistribution,
* if any, must include the following acknowledgment:
* "This product includes software developed by the
* Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowledgment may appear in the software itself,
* if and wherever such third-party acknowledgments normally appear.
*
* 4. The names "Apache" and "Apache Software Foundation" and
* "Apache POI" must not be used to endorse or promote products
* derived from this software without prior written permission. For
* written permission, please contact apache@apache.org.
*
* 5. Products derived from this software may not be called "Apache",
* "Apache POI", nor may "Apache" appear in their name, without
* prior written permission of the Apache Software Foundation.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* ====================================================================
*
* This software consists of voluntary contributions made by many
* individuals on behalf of the Apache Software Foundation. For more
* information on the Apache Software Foundation, please see
* <http://www.apache.org/>.
*/
package org.apache.poi.hwpf.model.types;
import org.apache.poi.util.BitField;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.util.StringUtil;
import org.apache.poi.util.HexDump;
import org.apache.poi.hdf.model.hdftypes.HDFType;
import org.apache.poi.hwpf.usermodel.*;
/**
* File information Block.
* NOTE: This source is automatically generated please do not modify this file. Either subclass or
* remove the record in src/records/definitions.
* @author Andrew C. Oliver
*/
public abstract class FIBAbstractType
implements HDFType
{
protected int field_1_wIdent;
protected int field_2_nFib;
protected int field_3_nProduct;
protected int field_4_lid;
protected int field_5_pnNext;
protected short field_6_options;
private static BitField fDot = new BitField(0x0001);
private static BitField fGlsy = new BitField(0x0002);
private static BitField fComplex = new BitField(0x0004);
private static BitField fHasPic = new BitField(0x0008);
private static BitField cQuickSaves = new BitField(0x00F0);
private static BitField fEncrypted = new BitField(0x0100);
private static BitField fWhichTblStm = new BitField(0x0200);
private static BitField fReadOnlyRecommended = new BitField(0x0400);
private static BitField fWriteReservation = new BitField(0x0800);
private static BitField fExtChar = new BitField(0x1000);
private static BitField fLoadOverride = new BitField(0x2000);
private static BitField fFarEast = new BitField(0x4000);
private static BitField fCrypto = new BitField(0x8000);
protected int field_7_nFibBack;
protected int field_8_lKey;
protected int field_9_envr;
protected short field_10_history;
private static BitField fMac = new BitField(0x0001);
private static BitField fEmptySpecial = new BitField(0x0002);
private static BitField fLoadOverridePage = new BitField(0x0004);
private static BitField fFutureSavedUndo = new BitField(0x0008);
private static BitField fWord97Saved = new BitField(0x0010);
private static BitField fSpare0 = new BitField(0x00FE);
protected int field_11_chs;
protected int field_12_chsTables;
protected int field_13_fcMin;
protected int field_14_fcMac;
public FIBAbstractType()
{
}
protected void fillFields(byte [] data, int offset)
{
field_1_wIdent = LittleEndian.getShort(data, 0x0 + offset);
field_2_nFib = LittleEndian.getShort(data, 0x2 + offset);
field_3_nProduct = LittleEndian.getShort(data, 0x4 + offset);
field_4_lid = LittleEndian.getShort(data, 0x6 + offset);
field_5_pnNext = LittleEndian.getShort(data, 0x8 + offset);
field_6_options = LittleEndian.getShort(data, 0xa + offset);
field_7_nFibBack = LittleEndian.getShort(data, 0xc + offset);
field_8_lKey = LittleEndian.getShort(data, 0xe + offset);
field_9_envr = LittleEndian.getShort(data, 0x10 + offset);
field_10_history = LittleEndian.getShort(data, 0x12 + offset);
field_11_chs = LittleEndian.getShort(data, 0x14 + offset);
field_12_chsTables = LittleEndian.getShort(data, 0x16 + offset);
field_13_fcMin = LittleEndian.getInt(data, 0x18 + offset);
field_14_fcMac = LittleEndian.getInt(data, 0x1c + offset);
}
public void serialize(byte[] data, int offset)
{
LittleEndian.putShort(data, 0x0 + offset, (short)field_1_wIdent);;
LittleEndian.putShort(data, 0x2 + offset, (short)field_2_nFib);;
LittleEndian.putShort(data, 0x4 + offset, (short)field_3_nProduct);;
LittleEndian.putShort(data, 0x6 + offset, (short)field_4_lid);;
LittleEndian.putShort(data, 0x8 + offset, (short)field_5_pnNext);;
LittleEndian.putShort(data, 0xa + offset, (short)field_6_options);;
LittleEndian.putShort(data, 0xc + offset, (short)field_7_nFibBack);;
LittleEndian.putShort(data, 0xe + offset, (short)field_8_lKey);;
LittleEndian.putShort(data, 0x10 + offset, (short)field_9_envr);;
LittleEndian.putShort(data, 0x12 + offset, (short)field_10_history);;
LittleEndian.putShort(data, 0x14 + offset, (short)field_11_chs);;
LittleEndian.putShort(data, 0x16 + offset, (short)field_12_chsTables);;
LittleEndian.putInt(data, 0x18 + offset, field_13_fcMin);;
LittleEndian.putInt(data, 0x1c + offset, field_14_fcMac);;
}
public String toString()
{
StringBuffer buffer = new StringBuffer();
buffer.append("[FIB]\n");
buffer.append(" .wIdent = ");
buffer.append(" (").append(getWIdent()).append(" )\n");
buffer.append(" .nFib = ");
buffer.append(" (").append(getNFib()).append(" )\n");
buffer.append(" .nProduct = ");
buffer.append(" (").append(getNProduct()).append(" )\n");
buffer.append(" .lid = ");
buffer.append(" (").append(getLid()).append(" )\n");
buffer.append(" .pnNext = ");
buffer.append(" (").append(getPnNext()).append(" )\n");
buffer.append(" .options = ");
buffer.append(" (").append(getOptions()).append(" )\n");
buffer.append(" .fDot = ").append(isFDot()).append('\n');
buffer.append(" .fGlsy = ").append(isFGlsy()).append('\n');
buffer.append(" .fComplex = ").append(isFComplex()).append('\n');
buffer.append(" .fHasPic = ").append(isFHasPic()).append('\n');
buffer.append(" .cQuickSaves = ").append(getCQuickSaves()).append('\n');
buffer.append(" .fEncrypted = ").append(isFEncrypted()).append('\n');
buffer.append(" .fWhichTblStm = ").append(isFWhichTblStm()).append('\n');
buffer.append(" .fReadOnlyRecommended = ").append(isFReadOnlyRecommended()).append('\n');
buffer.append(" .fWriteReservation = ").append(isFWriteReservation()).append('\n');
buffer.append(" .fExtChar = ").append(isFExtChar()).append('\n');
buffer.append(" .fLoadOverride = ").append(isFLoadOverride()).append('\n');
buffer.append(" .fFarEast = ").append(isFFarEast()).append('\n');
buffer.append(" .fCrypto = ").append(isFCrypto()).append('\n');
buffer.append(" .nFibBack = ");
buffer.append(" (").append(getNFibBack()).append(" )\n");
buffer.append(" .lKey = ");
buffer.append(" (").append(getLKey()).append(" )\n");
buffer.append(" .envr = ");
buffer.append(" (").append(getEnvr()).append(" )\n");
buffer.append(" .history = ");
buffer.append(" (").append(getHistory()).append(" )\n");
buffer.append(" .fMac = ").append(isFMac()).append('\n');
buffer.append(" .fEmptySpecial = ").append(isFEmptySpecial()).append('\n');
buffer.append(" .fLoadOverridePage = ").append(isFLoadOverridePage()).append('\n');
buffer.append(" .fFutureSavedUndo = ").append(isFFutureSavedUndo()).append('\n');
buffer.append(" .fWord97Saved = ").append(isFWord97Saved()).append('\n');
buffer.append(" .fSpare0 = ").append(getFSpare0()).append('\n');
buffer.append(" .chs = ");
buffer.append(" (").append(getChs()).append(" )\n");
buffer.append(" .chsTables = ");
buffer.append(" (").append(getChsTables()).append(" )\n");
buffer.append(" .fcMin = ");
buffer.append(" (").append(getFcMin()).append(" )\n");
buffer.append(" .fcMac = ");
buffer.append(" (").append(getFcMac()).append(" )\n");
buffer.append("[/FIB]\n");
return buffer.toString();
}
/**
* Size of record (exluding 4 byte header)
*/
public int getSize()
{
return 2 + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 4 + 4;
}
/**
* Get the wIdent field for the FIB record.
*/
public int getWIdent()
{
return field_1_wIdent;
}
/**
* Set the wIdent field for the FIB record.
*/
public void setWIdent(int field_1_wIdent)
{
this.field_1_wIdent = field_1_wIdent;
}
/**
* Get the nFib field for the FIB record.
*/
public int getNFib()
{
return field_2_nFib;
}
/**
* Set the nFib field for the FIB record.
*/
public void setNFib(int field_2_nFib)
{
this.field_2_nFib = field_2_nFib;
}
/**
* Get the nProduct field for the FIB record.
*/
public int getNProduct()
{
return field_3_nProduct;
}
/**
* Set the nProduct field for the FIB record.
*/
public void setNProduct(int field_3_nProduct)
{
this.field_3_nProduct = field_3_nProduct;
}
/**
* Get the lid field for the FIB record.
*/
public int getLid()
{
return field_4_lid;
}
/**
* Set the lid field for the FIB record.
*/
public void setLid(int field_4_lid)
{
this.field_4_lid = field_4_lid;
}
/**
* Get the pnNext field for the FIB record.
*/
public int getPnNext()
{
return field_5_pnNext;
}
/**
* Set the pnNext field for the FIB record.
*/
public void setPnNext(int field_5_pnNext)
{
this.field_5_pnNext = field_5_pnNext;
}
/**
* Get the options field for the FIB record.
*/
public short getOptions()
{
return field_6_options;
}
/**
* Set the options field for the FIB record.
*/
public void setOptions(short field_6_options)
{
this.field_6_options = field_6_options;
}
/**
* Get the nFibBack field for the FIB record.
*/
public int getNFibBack()
{
return field_7_nFibBack;
}
/**
* Set the nFibBack field for the FIB record.
*/
public void setNFibBack(int field_7_nFibBack)
{
this.field_7_nFibBack = field_7_nFibBack;
}
/**
* Get the lKey field for the FIB record.
*/
public int getLKey()
{
return field_8_lKey;
}
/**
* Set the lKey field for the FIB record.
*/
public void setLKey(int field_8_lKey)
{
this.field_8_lKey = field_8_lKey;
}
/**
* Get the envr field for the FIB record.
*/
public int getEnvr()
{
return field_9_envr;
}
/**
* Set the envr field for the FIB record.
*/
public void setEnvr(int field_9_envr)
{
this.field_9_envr = field_9_envr;
}
/**
* Get the history field for the FIB record.
*/
public short getHistory()
{
return field_10_history;
}
/**
* Set the history field for the FIB record.
*/
public void setHistory(short field_10_history)
{
this.field_10_history = field_10_history;
}
/**
* Get the chs field for the FIB record.
*/
public int getChs()
{
return field_11_chs;
}
/**
* Set the chs field for the FIB record.
*/
public void setChs(int field_11_chs)
{
this.field_11_chs = field_11_chs;
}
/**
* Get the chsTables field for the FIB record.
*/
public int getChsTables()
{
return field_12_chsTables;
}
/**
* Set the chsTables field for the FIB record.
*/
public void setChsTables(int field_12_chsTables)
{
this.field_12_chsTables = field_12_chsTables;
}
/**
* Get the fcMin field for the FIB record.
*/
public int getFcMin()
{
return field_13_fcMin;
}
/**
* Set the fcMin field for the FIB record.
*/
public void setFcMin(int field_13_fcMin)
{
this.field_13_fcMin = field_13_fcMin;
}
/**
* Get the fcMac field for the FIB record.
*/
public int getFcMac()
{
return field_14_fcMac;
}
/**
* Set the fcMac field for the FIB record.
*/
public void setFcMac(int field_14_fcMac)
{
this.field_14_fcMac = field_14_fcMac;
}
/**
* Sets the fDot field value.
*
*/
public void setFDot(boolean value)
{
field_6_options = (short)fDot.setBoolean(field_6_options, value);
}
/**
*
* @return the fDot field value.
*/
public boolean isFDot()
{
return fDot.isSet(field_6_options);
}
/**
* Sets the fGlsy field value.
*
*/
public void setFGlsy(boolean value)
{
field_6_options = (short)fGlsy.setBoolean(field_6_options, value);
}
/**
*
* @return the fGlsy field value.
*/
public boolean isFGlsy()
{
return fGlsy.isSet(field_6_options);
}
/**
* Sets the fComplex field value.
*
*/
public void setFComplex(boolean value)
{
field_6_options = (short)fComplex.setBoolean(field_6_options, value);
}
/**
*
* @return the fComplex field value.
*/
public boolean isFComplex()
{
return fComplex.isSet(field_6_options);
}
/**
* Sets the fHasPic field value.
*
*/
public void setFHasPic(boolean value)
{
field_6_options = (short)fHasPic.setBoolean(field_6_options, value);
}
/**
*
* @return the fHasPic field value.
*/
public boolean isFHasPic()
{
return fHasPic.isSet(field_6_options);
}
/**
* Sets the cQuickSaves field value.
*
*/
public void setCQuickSaves(byte value)
{
field_6_options = (short)cQuickSaves.setValue(field_6_options, value);
}
/**
*
* @return the cQuickSaves field value.
*/
public byte getCQuickSaves()
{
return ( byte )cQuickSaves.getValue(field_6_options);
}
/**
* Sets the fEncrypted field value.
*
*/
public void setFEncrypted(boolean value)
{
field_6_options = (short)fEncrypted.setBoolean(field_6_options, value);
}
/**
*
* @return the fEncrypted field value.
*/
public boolean isFEncrypted()
{
return fEncrypted.isSet(field_6_options);
}
/**
* Sets the fWhichTblStm field value.
*
*/
public void setFWhichTblStm(boolean value)
{
field_6_options = (short)fWhichTblStm.setBoolean(field_6_options, value);
}
/**
*
* @return the fWhichTblStm field value.
*/
public boolean isFWhichTblStm()
{
return fWhichTblStm.isSet(field_6_options);
}
/**
* Sets the fReadOnlyRecommended field value.
*
*/
public void setFReadOnlyRecommended(boolean value)
{
field_6_options = (short)fReadOnlyRecommended.setBoolean(field_6_options, value);
}
/**
*
* @return the fReadOnlyRecommended field value.
*/
public boolean isFReadOnlyRecommended()
{
return fReadOnlyRecommended.isSet(field_6_options);
}
/**
* Sets the fWriteReservation field value.
*
*/
public void setFWriteReservation(boolean value)
{
field_6_options = (short)fWriteReservation.setBoolean(field_6_options, value);
}
/**
*
* @return the fWriteReservation field value.
*/
public boolean isFWriteReservation()
{
return fWriteReservation.isSet(field_6_options);
}
/**
* Sets the fExtChar field value.
*
*/
public void setFExtChar(boolean value)
{
field_6_options = (short)fExtChar.setBoolean(field_6_options, value);
}
/**
*
* @return the fExtChar field value.
*/
public boolean isFExtChar()
{
return fExtChar.isSet(field_6_options);
}
/**
* Sets the fLoadOverride field value.
*
*/
public void setFLoadOverride(boolean value)
{
field_6_options = (short)fLoadOverride.setBoolean(field_6_options, value);
}
/**
*
* @return the fLoadOverride field value.
*/
public boolean isFLoadOverride()
{
return fLoadOverride.isSet(field_6_options);
}
/**
* Sets the fFarEast field value.
*
*/
public void setFFarEast(boolean value)
{
field_6_options = (short)fFarEast.setBoolean(field_6_options, value);
}
/**
*
* @return the fFarEast field value.
*/
public boolean isFFarEast()
{
return fFarEast.isSet(field_6_options);
}
/**
* Sets the fCrypto field value.
*
*/
public void setFCrypto(boolean value)
{
field_6_options = (short)fCrypto.setBoolean(field_6_options, value);
}
/**
*
* @return the fCrypto field value.
*/
public boolean isFCrypto()
{
return fCrypto.isSet(field_6_options);
}
/**
* Sets the fMac field value.
*
*/
public void setFMac(boolean value)
{
field_10_history = (short)fMac.setBoolean(field_10_history, value);
}
/**
*
* @return the fMac field value.
*/
public boolean isFMac()
{
return fMac.isSet(field_10_history);
}
/**
* Sets the fEmptySpecial field value.
*
*/
public void setFEmptySpecial(boolean value)
{
field_10_history = (short)fEmptySpecial.setBoolean(field_10_history, value);
}
/**
*
* @return the fEmptySpecial field value.
*/
public boolean isFEmptySpecial()
{
return fEmptySpecial.isSet(field_10_history);
}
/**
* Sets the fLoadOverridePage field value.
*
*/
public void setFLoadOverridePage(boolean value)
{
field_10_history = (short)fLoadOverridePage.setBoolean(field_10_history, value);
}
/**
*
* @return the fLoadOverridePage field value.
*/
public boolean isFLoadOverridePage()
{
return fLoadOverridePage.isSet(field_10_history);
}
/**
* Sets the fFutureSavedUndo field value.
*
*/
public void setFFutureSavedUndo(boolean value)
{
field_10_history = (short)fFutureSavedUndo.setBoolean(field_10_history, value);
}
/**
*
* @return the fFutureSavedUndo field value.
*/
public boolean isFFutureSavedUndo()
{
return fFutureSavedUndo.isSet(field_10_history);
}
/**
* Sets the fWord97Saved field value.
*
*/
public void setFWord97Saved(boolean value)
{
field_10_history = (short)fWord97Saved.setBoolean(field_10_history, value);
}
/**
*
* @return the fWord97Saved field value.
*/
public boolean isFWord97Saved()
{
return fWord97Saved.isSet(field_10_history);
}
/**
* Sets the fSpare0 field value.
*
*/
public void setFSpare0(byte value)
{
field_10_history = (short)fSpare0.setValue(field_10_history, value);
}
/**
*
* @return the fSpare0 field value.
*/
public byte getFSpare0()
{
return ( byte )fSpare0.getValue(field_10_history);
}
} // END OF CLASS

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,373 @@
/* ====================================================================
* The Apache Software License, Version 1.1
*
* Copyright (c) 2003 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
*
* 3. The end-user documentation included with the redistribution,
* if any, must include the following acknowledgment:
* "This product includes software developed by the
* Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowledgment may appear in the software itself,
* if and wherever such third-party acknowledgments normally appear.
*
* 4. The names "Apache" and "Apache Software Foundation" and
* "Apache POI" must not be used to endorse or promote products
* derived from this software without prior written permission. For
* written permission, please contact apache@apache.org.
*
* 5. Products derived from this software may not be called "Apache",
* "Apache POI", nor may "Apache" appear in their name, without
* prior written permission of the Apache Software Foundation.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* ====================================================================
*
* This software consists of voluntary contributions made by many
* individuals on behalf of the Apache Software Foundation. For more
* information on the Apache Software Foundation, please see
* <http://www.apache.org/>.
*/
package org.apache.poi.hwpf.model.types;
import org.apache.poi.util.BitField;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.util.StringUtil;
import org.apache.poi.util.HexDump;
import org.apache.poi.hdf.model.hdftypes.HDFType;
import org.apache.poi.hwpf.usermodel.*;
/**
* Table Properties.
* NOTE: This source is automatically generated please do not modify this file. Either subclass or
* remove the record in src/records/definitions.
* @author S. Ryan Ackley
*/
public abstract class TAPAbstractType
implements HDFType
{
protected int field_1_jc;
protected int field_2_dxaGapHalf;
protected int field_3_dyaRowHeight;
protected boolean field_4_fCantSplit;
protected boolean field_5_fTableHeader;
protected int field_6_tlp;
protected short field_7_itcMac;
protected short[] field_8_rgdxaCenter;
protected TableCellDescriptor[] field_9_rgtc;
protected ShadingDescriptor[] field_10_rgshd;
protected BorderCode field_11_brcBottom;
protected BorderCode field_12_brcTop;
protected BorderCode field_13_brcLeft;
protected BorderCode field_14_brcRight;
protected BorderCode field_15_brcVertical;
protected BorderCode field_16_brcHorizontal;
public TAPAbstractType()
{
}
/**
* Size of record (exluding 4 byte header)
*/
public int getSize()
{
return 4 + + 2 + 4 + 4 + 0 + 0 + 4 + 2 + 130 + 0 + 0 + 4 + 4 + 4 + 4 + 4 + 4;
}
/**
* Get the jc field for the TAP record.
*/
public int getJc()
{
return field_1_jc;
}
/**
* Set the jc field for the TAP record.
*/
public void setJc(int field_1_jc)
{
this.field_1_jc = field_1_jc;
}
/**
* Get the dxaGapHalf field for the TAP record.
*/
public int getDxaGapHalf()
{
return field_2_dxaGapHalf;
}
/**
* Set the dxaGapHalf field for the TAP record.
*/
public void setDxaGapHalf(int field_2_dxaGapHalf)
{
this.field_2_dxaGapHalf = field_2_dxaGapHalf;
}
/**
* Get the dyaRowHeight field for the TAP record.
*/
public int getDyaRowHeight()
{
return field_3_dyaRowHeight;
}
/**
* Set the dyaRowHeight field for the TAP record.
*/
public void setDyaRowHeight(int field_3_dyaRowHeight)
{
this.field_3_dyaRowHeight = field_3_dyaRowHeight;
}
/**
* Get the fCantSplit field for the TAP record.
*/
public boolean getFCantSplit()
{
return field_4_fCantSplit;
}
/**
* Set the fCantSplit field for the TAP record.
*/
public void setFCantSplit(boolean field_4_fCantSplit)
{
this.field_4_fCantSplit = field_4_fCantSplit;
}
/**
* Get the fTableHeader field for the TAP record.
*/
public boolean getFTableHeader()
{
return field_5_fTableHeader;
}
/**
* Set the fTableHeader field for the TAP record.
*/
public void setFTableHeader(boolean field_5_fTableHeader)
{
this.field_5_fTableHeader = field_5_fTableHeader;
}
/**
* Get the tlp field for the TAP record.
*/
public int getTlp()
{
return field_6_tlp;
}
/**
* Set the tlp field for the TAP record.
*/
public void setTlp(int field_6_tlp)
{
this.field_6_tlp = field_6_tlp;
}
/**
* Get the itcMac field for the TAP record.
*/
public short getItcMac()
{
return field_7_itcMac;
}
/**
* Set the itcMac field for the TAP record.
*/
public void setItcMac(short field_7_itcMac)
{
this.field_7_itcMac = field_7_itcMac;
}
/**
* Get the rgdxaCenter field for the TAP record.
*/
public short[] getRgdxaCenter()
{
return field_8_rgdxaCenter;
}
/**
* Set the rgdxaCenter field for the TAP record.
*/
public void setRgdxaCenter(short[] field_8_rgdxaCenter)
{
this.field_8_rgdxaCenter = field_8_rgdxaCenter;
}
/**
* Get the rgtc field for the TAP record.
*/
public TableCellDescriptor[] getRgtc()
{
return field_9_rgtc;
}
/**
* Set the rgtc field for the TAP record.
*/
public void setRgtc(TableCellDescriptor[] field_9_rgtc)
{
this.field_9_rgtc = field_9_rgtc;
}
/**
* Get the rgshd field for the TAP record.
*/
public ShadingDescriptor[] getRgshd()
{
return field_10_rgshd;
}
/**
* Set the rgshd field for the TAP record.
*/
public void setRgshd(ShadingDescriptor[] field_10_rgshd)
{
this.field_10_rgshd = field_10_rgshd;
}
/**
* Get the brcBottom field for the TAP record.
*/
public BorderCode getBrcBottom()
{
return field_11_brcBottom;
}
/**
* Set the brcBottom field for the TAP record.
*/
public void setBrcBottom(BorderCode field_11_brcBottom)
{
this.field_11_brcBottom = field_11_brcBottom;
}
/**
* Get the brcTop field for the TAP record.
*/
public BorderCode getBrcTop()
{
return field_12_brcTop;
}
/**
* Set the brcTop field for the TAP record.
*/
public void setBrcTop(BorderCode field_12_brcTop)
{
this.field_12_brcTop = field_12_brcTop;
}
/**
* Get the brcLeft field for the TAP record.
*/
public BorderCode getBrcLeft()
{
return field_13_brcLeft;
}
/**
* Set the brcLeft field for the TAP record.
*/
public void setBrcLeft(BorderCode field_13_brcLeft)
{
this.field_13_brcLeft = field_13_brcLeft;
}
/**
* Get the brcRight field for the TAP record.
*/
public BorderCode getBrcRight()
{
return field_14_brcRight;
}
/**
* Set the brcRight field for the TAP record.
*/
public void setBrcRight(BorderCode field_14_brcRight)
{
this.field_14_brcRight = field_14_brcRight;
}
/**
* Get the brcVertical field for the TAP record.
*/
public BorderCode getBrcVertical()
{
return field_15_brcVertical;
}
/**
* Set the brcVertical field for the TAP record.
*/
public void setBrcVertical(BorderCode field_15_brcVertical)
{
this.field_15_brcVertical = field_15_brcVertical;
}
/**
* Get the brcHorizontal field for the TAP record.
*/
public BorderCode getBrcHorizontal()
{
return field_16_brcHorizontal;
}
/**
* Set the brcHorizontal field for the TAP record.
*/
public void setBrcHorizontal(BorderCode field_16_brcHorizontal)
{
this.field_16_brcHorizontal = field_16_brcHorizontal;
}
} // END OF CLASS

View File

@ -0,0 +1,437 @@
/* ====================================================================
* The Apache Software License, Version 1.1
*
* Copyright (c) 2003 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
*
* 3. The end-user documentation included with the redistribution,
* if any, must include the following acknowledgment:
* "This product includes software developed by the
* Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowledgment may appear in the software itself,
* if and wherever such third-party acknowledgments normally appear.
*
* 4. The names "Apache" and "Apache Software Foundation" and
* "Apache POI" must not be used to endorse or promote products
* derived from this software without prior written permission. For
* written permission, please contact apache@apache.org.
*
* 5. Products derived from this software may not be called "Apache",
* "Apache POI", nor may "Apache" appear in their name, without
* prior written permission of the Apache Software Foundation.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* ====================================================================
*
* This software consists of voluntary contributions made by many
* individuals on behalf of the Apache Software Foundation. For more
* information on the Apache Software Foundation, please see
* <http://www.apache.org/>.
*/
package org.apache.poi.hwpf.model.types;
import org.apache.poi.util.BitField;
import org.apache.poi.util.LittleEndian;
import org.apache.poi.util.StringUtil;
import org.apache.poi.util.HexDump;
import org.apache.poi.hdf.model.hdftypes.HDFType;
import org.apache.poi.hwpf.usermodel.*;
/**
* Table Cell Descriptor.
* NOTE: This source is automatically generated please do not modify this file. Either subclass or
* remove the record in src/records/definitions.
* @author S. Ryan Ackley
*/
public abstract class TCAbstractType
implements HDFType
{
protected short field_1_rgf;
private static BitField fFirstMerged = new BitField(0x0001);
private static BitField fMerged = new BitField(0x0002);
private static BitField fVertical = new BitField(0x0004);
private static BitField fBackward = new BitField(0x0008);
private static BitField fRotateFont = new BitField(0x0010);
private static BitField fVertMerge = new BitField(0x0020);
private static BitField fVertRestart = new BitField(0x0040);
private static BitField vertAlign = new BitField(0x0180);
protected short field_2_unused;
protected BorderCode field_3_brcTop;
protected BorderCode field_4_brcLeft;
protected BorderCode field_5_brcBottom;
protected BorderCode field_6_brcRight;
public TCAbstractType()
{
}
protected void fillFields(byte [] data, int offset)
{
field_1_rgf = LittleEndian.getShort(data, 0x0 + offset);
field_2_unused = LittleEndian.getShort(data, 0x2 + offset);
field_3_brcTop = new BorderCode(data, 0x4 + offset);
field_4_brcLeft = new BorderCode(data, 0x8 + offset);
field_5_brcBottom = new BorderCode(data, 0xc + offset);
field_6_brcRight = new BorderCode(data, 0x10 + offset);
}
public void serialize(byte[] data, int offset)
{
LittleEndian.putShort(data, 0x0 + offset, (short)field_1_rgf);;
LittleEndian.putShort(data, 0x2 + offset, (short)field_2_unused);;
field_3_brcTop.serialize(data, 0x4 + offset);;
field_4_brcLeft.serialize(data, 0x8 + offset);;
field_5_brcBottom.serialize(data, 0xc + offset);;
field_6_brcRight.serialize(data, 0x10 + offset);;
}
public String toString()
{
StringBuffer buffer = new StringBuffer();
buffer.append("[TC]\n");
buffer.append(" .rgf = ");
buffer.append(" (").append(getRgf()).append(" )\n");
buffer.append(" .fFirstMerged = ").append(isFFirstMerged()).append('\n');
buffer.append(" .fMerged = ").append(isFMerged()).append('\n');
buffer.append(" .fVertical = ").append(isFVertical()).append('\n');
buffer.append(" .fBackward = ").append(isFBackward()).append('\n');
buffer.append(" .fRotateFont = ").append(isFRotateFont()).append('\n');
buffer.append(" .fVertMerge = ").append(isFVertMerge()).append('\n');
buffer.append(" .fVertRestart = ").append(isFVertRestart()).append('\n');
buffer.append(" .vertAlign = ").append(getVertAlign()).append('\n');
buffer.append(" .unused = ");
buffer.append(" (").append(getUnused()).append(" )\n");
buffer.append(" .brcTop = ");
buffer.append(" (").append(getBrcTop()).append(" )\n");
buffer.append(" .brcLeft = ");
buffer.append(" (").append(getBrcLeft()).append(" )\n");
buffer.append(" .brcBottom = ");
buffer.append(" (").append(getBrcBottom()).append(" )\n");
buffer.append(" .brcRight = ");
buffer.append(" (").append(getBrcRight()).append(" )\n");
buffer.append("[/TC]\n");
return buffer.toString();
}
/**
* Size of record (exluding 4 byte header)
*/
public int getSize()
{
return 4 + + 2 + 2 + 4 + 4 + 4 + 4;
}
/**
* Get the rgf field for the TC record.
*/
public short getRgf()
{
return field_1_rgf;
}
/**
* Set the rgf field for the TC record.
*/
public void setRgf(short field_1_rgf)
{
this.field_1_rgf = field_1_rgf;
}
/**
* Get the unused field for the TC record.
*/
public short getUnused()
{
return field_2_unused;
}
/**
* Set the unused field for the TC record.
*/
public void setUnused(short field_2_unused)
{
this.field_2_unused = field_2_unused;
}
/**
* Get the brcTop field for the TC record.
*/
public BorderCode getBrcTop()
{
return field_3_brcTop;
}
/**
* Set the brcTop field for the TC record.
*/
public void setBrcTop(BorderCode field_3_brcTop)
{
this.field_3_brcTop = field_3_brcTop;
}
/**
* Get the brcLeft field for the TC record.
*/
public BorderCode getBrcLeft()
{
return field_4_brcLeft;
}
/**
* Set the brcLeft field for the TC record.
*/
public void setBrcLeft(BorderCode field_4_brcLeft)
{
this.field_4_brcLeft = field_4_brcLeft;
}
/**
* Get the brcBottom field for the TC record.
*/
public BorderCode getBrcBottom()
{
return field_5_brcBottom;
}
/**
* Set the brcBottom field for the TC record.
*/
public void setBrcBottom(BorderCode field_5_brcBottom)
{
this.field_5_brcBottom = field_5_brcBottom;
}
/**
* Get the brcRight field for the TC record.
*/
public BorderCode getBrcRight()
{
return field_6_brcRight;
}
/**
* Set the brcRight field for the TC record.
*/
public void setBrcRight(BorderCode field_6_brcRight)
{
this.field_6_brcRight = field_6_brcRight;
}
/**
* Sets the fFirstMerged field value.
*
*/
public void setFFirstMerged(boolean value)
{
field_1_rgf = (short)fFirstMerged.setBoolean(field_1_rgf, value);
}
/**
*
* @return the fFirstMerged field value.
*/
public boolean isFFirstMerged()
{
return fFirstMerged.isSet(field_1_rgf);
}
/**
* Sets the fMerged field value.
*
*/
public void setFMerged(boolean value)
{
field_1_rgf = (short)fMerged.setBoolean(field_1_rgf, value);
}
/**
*
* @return the fMerged field value.
*/
public boolean isFMerged()
{
return fMerged.isSet(field_1_rgf);
}
/**
* Sets the fVertical field value.
*
*/
public void setFVertical(boolean value)
{
field_1_rgf = (short)fVertical.setBoolean(field_1_rgf, value);
}
/**
*
* @return the fVertical field value.
*/
public boolean isFVertical()
{
return fVertical.isSet(field_1_rgf);
}
/**
* Sets the fBackward field value.
*
*/
public void setFBackward(boolean value)
{
field_1_rgf = (short)fBackward.setBoolean(field_1_rgf, value);
}
/**
*
* @return the fBackward field value.
*/
public boolean isFBackward()
{
return fBackward.isSet(field_1_rgf);
}
/**
* Sets the fRotateFont field value.
*
*/
public void setFRotateFont(boolean value)
{
field_1_rgf = (short)fRotateFont.setBoolean(field_1_rgf, value);
}
/**
*
* @return the fRotateFont field value.
*/
public boolean isFRotateFont()
{
return fRotateFont.isSet(field_1_rgf);
}
/**
* Sets the fVertMerge field value.
*
*/
public void setFVertMerge(boolean value)
{
field_1_rgf = (short)fVertMerge.setBoolean(field_1_rgf, value);
}
/**
*
* @return the fVertMerge field value.
*/
public boolean isFVertMerge()
{
return fVertMerge.isSet(field_1_rgf);
}
/**
* Sets the fVertRestart field value.
*
*/
public void setFVertRestart(boolean value)
{
field_1_rgf = (short)fVertRestart.setBoolean(field_1_rgf, value);
}
/**
*
* @return the fVertRestart field value.
*/
public boolean isFVertRestart()
{
return fVertRestart.isSet(field_1_rgf);
}
/**
* Sets the vertAlign field value.
*
*/
public void setVertAlign(byte value)
{
field_1_rgf = (short)vertAlign.setValue(field_1_rgf, value);
}
/**
*
* @return the vertAlign field value.
*/
public byte getVertAlign()
{
return ( byte )vertAlign.getValue(field_1_rgf);
}
} // END OF CLASS