javadocs cleanup

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@712196 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Yegor Kozlov 2008-11-07 16:57:23 +00:00
parent 0d7cb5c968
commit 2517aa0e42
71 changed files with 577 additions and 657 deletions

View File

@ -1010,7 +1010,7 @@ FORREST_HOME environment variable!</echo>
warn-unless-xslt-is-available" warn-unless-xslt-is-available"
description="Generates the API documentation"> description="Generates the API documentation">
<javadoc verbose="false" author="true" destdir="${apidocs.report.dir}" <javadoc verbose="false" author="true" destdir="${apidocs.report.dir}"
windowtitle="POI API Documentation" use="true" version="true"> windowtitle="POI API Documentation" use="true" version="true" maxmemory="256M">
<packageset dir="${main.src}" defaultexcludes="yes"> <packageset dir="${main.src}" defaultexcludes="yes">
<include name="org/apache/poi/**"/> <include name="org/apache/poi/**"/>
@ -1022,7 +1022,7 @@ FORREST_HOME environment variable!</echo>
<packageset dir="${contrib.src}" defaultexcludes="yes"> <packageset dir="${contrib.src}" defaultexcludes="yes">
<include name="org/apache/poi/**"/> <include name="org/apache/poi/**"/>
</packageset> </packageset>
<packageset dir="${examples.src}" defaultexcludes="yes"> <packageset dir="${ooxml.src}" defaultexcludes="yes">
<include name="org/apache/poi/**"/> <include name="org/apache/poi/**"/>
</packageset> </packageset>
@ -1030,7 +1030,7 @@ FORREST_HOME environment variable!</echo>
<path refid="main.classpath"/> <path refid="main.classpath"/>
<path refid="scratchpad.classpath"/> <path refid="scratchpad.classpath"/>
<path refid="contrib.classpath"/> <path refid="contrib.classpath"/>
<path refid="examples.classpath"/> <path refid="ooxml.classpath"/>
<path path="${env.CLASSPATH}"/> <path path="${env.CLASSPATH}"/>
</classpath> </classpath>

View File

@ -52,7 +52,7 @@ public final class BiffViewer {
/** /**
* Create an array of records from an input stream * Create an array of records from an input stream
* *
*@param in the InputStream from which the records will be obtained *@param is the InputStream from which the records will be obtained
*@return an array of Records created from the InputStream *@return an array of Records created from the InputStream
*@exception RecordFormatException on error processing the InputStream *@exception RecordFormatException on error processing the InputStream
*/ */

View File

@ -148,9 +148,7 @@ public final class Sheet implements Model {
* to the passed in records and references to those records held. This function * to the passed in records and references to those records held. This function
* is normally called via Workbook. * is normally called via Workbook.
* *
* @param inRecs array containing those records in the sheet in sequence (normally obtained from RecordFactory) * @param rs the stream to read records from
* @param sheetnum integer specifying the sheet's number (0,1 or 2 in this release)
* @param offset of the sheet's BOF record
* *
* @return Sheet object with all values set to those read from the file * @return Sheet object with all values set to those read from the file
* *
@ -653,7 +651,6 @@ public final class Sheet implements Model {
* at what this sets it to. * at what this sets it to.
* *
* @param row the row record to be added * @param row the row record to be added
* @see #setLoc(int)
*/ */
public void addRow(RowRecord row) public void addRow(RowRecord row)
@ -706,7 +703,6 @@ public final class Sheet implements Model {
* subsequent calls will return values in (physical) sequence or NULL when you get to the end. * subsequent calls will return values in (physical) sequence or NULL when you get to the end.
* *
* @return CellValueRecordInterface representing the next value record or NULL if there are no more * @return CellValueRecordInterface representing the next value record or NULL if there are no more
* @see #setLoc(int)
*/ */
public CellValueRecordInterface[] getValueRecords() { public CellValueRecordInterface[] getValueRecords() {
return _rowsAggregate.getValueRecords(); return _rowsAggregate.getValueRecords();
@ -723,8 +719,6 @@ public final class Sheet implements Model {
* subsequent calls will return rows in (physical) sequence or NULL when you get to the end. * subsequent calls will return rows in (physical) sequence or NULL when you get to the end.
* *
* @return RowRecord representing the next row record or NULL if there are no more * @return RowRecord representing the next row record or NULL if there are no more
* @see #setLoc(int)
*
*/ */
public RowRecord getNextRow() { public RowRecord getNextRow() {
if (rowRecIterator == null) if (rowRecIterator == null)
@ -751,7 +745,6 @@ public final class Sheet implements Model {
* *
* @param rownum which row to return (careful with LOC) * @param rownum which row to return (careful with LOC)
* @return RowRecord representing the next row record or NULL if there are no more * @return RowRecord representing the next row record or NULL if there are no more
* @see #setLoc(int)
* *
*/ */
public RowRecord getRow(int rownum) { public RowRecord getRow(int rownum) {
@ -985,7 +978,7 @@ public final class Sheet implements Model {
* @param columnIndex index * @param columnIndex index
* @see org.apache.poi.hssf.record.DefaultColWidthRecord * @see org.apache.poi.hssf.record.DefaultColWidthRecord
* @see org.apache.poi.hssf.record.ColumnInfoRecord * @see org.apache.poi.hssf.record.ColumnInfoRecord
* @see #setColumnWidth(short,short) * @see #setColumnWidth(int, int)
* @return column width in units of 1/256th of a character width * @return column width in units of 1/256th of a character width
*/ */
@ -1036,10 +1029,10 @@ public final class Sheet implements Model {
/** /**
* Get the hidden property for a given column. * Get the hidden property for a given column.
* @param column index * @param columnIndex column index
* @see org.apache.poi.hssf.record.DefaultColWidthRecord * @see org.apache.poi.hssf.record.DefaultColWidthRecord
* @see org.apache.poi.hssf.record.ColumnInfoRecord * @see org.apache.poi.hssf.record.ColumnInfoRecord
* @see #setColumnHidden(short,boolean) * @see #setColumnHidden(int, boolean)
* @return whether the column is hidden or not. * @return whether the column is hidden or not.
*/ */
public boolean isColumnHidden(int columnIndex) { public boolean isColumnHidden(int columnIndex) {

View File

@ -87,7 +87,7 @@ public final class CFHeaderRecord extends Record {
/** /**
* Set cell ranges list to a single cell range and * Set cell ranges list to a single cell range and
* modify the enclosing cell range accordingly. * modify the enclosing cell range accordingly.
* @param List cellRanges - list of CellRange objects * @param cellRanges - list of CellRange objects
*/ */
public void setCellRanges(CellRangeAddress[] cellRanges) public void setCellRanges(CellRangeAddress[] cellRanges)
{ {

View File

@ -437,7 +437,7 @@ public final class CFRuleRecord extends Record {
* Subclasses should implement this so that their data is passed back in a * Subclasses should implement this so that their data is passed back in a
* byte array. * byte array.
* *
* @param offset to begin writing at * @param pOffset to begin writing at
* @param data byte array containing instance data * @param data byte array containing instance data
* @return number of bytes written * @return number of bytes written
*/ */

View File

@ -120,7 +120,7 @@ public final class ColumnInfoRecord extends Record {
/** /**
* set whether or not these cells are hidden * set whether or not these cells are hidden
* @param ishidden - whether the cells are hidden. * @param ishidden - whether the cells are hidden.
* @see #setOptions(short) * @see #setOptions(int)
*/ */
public void setHidden(boolean ishidden) public void setHidden(boolean ishidden)
@ -130,7 +130,7 @@ public final class ColumnInfoRecord extends Record {
/** /**
* set the outline level for the cells * set the outline level for the cells
* @see #setOptions(short) * @see #setOptions(int)
* @param olevel -outline level for the cells * @param olevel -outline level for the cells
*/ */
@ -142,7 +142,7 @@ public final class ColumnInfoRecord extends Record {
/** /**
* set whether the cells are collapsed * set whether the cells are collapsed
* @param iscollapsed - wether the cells are collapsed * @param iscollapsed - wether the cells are collapsed
* @see #setOptions(short) * @see #setOptions(int)
*/ */
public void setCollapsed(boolean iscollapsed) public void setCollapsed(boolean iscollapsed)
@ -206,7 +206,7 @@ public final class ColumnInfoRecord extends Record {
/** /**
* get whether or not these cells are hidden * get whether or not these cells are hidden
* @return whether the cells are hidden. * @return whether the cells are hidden.
* @see #setOptions(short) * @see #setOptions(int)
*/ */
public boolean getHidden() public boolean getHidden()
@ -216,7 +216,7 @@ public final class ColumnInfoRecord extends Record {
/** /**
* get the outline level for the cells * get the outline level for the cells
* @see #setOptions(short) * @see #setOptions(int)
* @return outline level for the cells * @return outline level for the cells
*/ */
@ -228,7 +228,7 @@ public final class ColumnInfoRecord extends Record {
/** /**
* get whether the cells are collapsed * get whether the cells are collapsed
* @return wether the cells are collapsed * @return wether the cells are collapsed
* @see #setOptions(short) * @see #setOptions(int)
*/ */
public boolean getCollapsed() public boolean getCollapsed()

View File

@ -148,7 +148,7 @@ public final class DBCellRecord extends Record {
} }
/** /**
* @returns the size of the group of <tt>DBCellRecord</tt>s needed to encode * @return the size of the group of <tt>DBCellRecord</tt>s needed to encode
* the specified number of blocks and rows * the specified number of blocks and rows
*/ */
public static int calculateSizeOfRecords(int nBlocks, int nRows) { public static int calculateSizeOfRecords(int nBlocks, int nRows) {

View File

@ -66,7 +66,7 @@ public final class DVRecord extends Record {
/** /**
* Option flags field * Option flags field
* *
* @see org.apache.poi.hssf.util.HSSFDataValidation utility class * @see HSSFDataValidation utility class
*/ */
private static final BitField opt_data_type = new BitField(0x0000000F); private static final BitField opt_data_type = new BitField(0x0000000F);
private static final BitField opt_error_style = new BitField(0x00000070); private static final BitField opt_error_style = new BitField(0x00000070);
@ -133,7 +133,7 @@ public final class DVRecord extends Record {
// --> start option flags // --> start option flags
/** /**
* @return the condition data type * @return the condition data type
* @see DVConstraint.ValidationType * @see org.apache.poi.hssf.usermodel.DVConstraint.ValidationType
*/ */
public int getDataType() { public int getDataType() {
return opt_data_type.getValue(_option_flags); return opt_data_type.getValue(_option_flags);
@ -141,7 +141,7 @@ public final class DVRecord extends Record {
/** /**
* @return the condition error style * @return the condition error style
* @see HSSFDataValidation.ErrorStyle * @see org.apache.poi.hssf.usermodel.HSSFDataValidation.ErrorStyle
*/ */
public int getErrorStyle() { public int getErrorStyle() {
return opt_error_style.getValue(_option_flags); return opt_error_style.getValue(_option_flags);
@ -189,7 +189,7 @@ public final class DVRecord extends Record {
/** /**
* get the condition operator * get the condition operator
* @return the condition operator * @return the condition operator
* @see org.apache.poi.hssf.util.HSSFDataValidation utility class * @see HSSFDataValidation utility class
*/ */
public int getConditionOperator() { public int getConditionOperator() {
return opt_condition_operator.getValue(_option_flags); return opt_condition_operator.getValue(_option_flags);

View File

@ -90,28 +90,28 @@ public final class FileSharingRecord extends Record {
} }
/** /**
* @param hashed password * @param password hashed password
*/ */
public void setPassword(short password) { public void setPassword(short password) {
field_2_password = password; field_2_password = password;
} }
/** /**
* @returns password hashed with hashPassword() (very lame) * @return password hashed with hashPassword() (very lame)
*/ */
public short getPassword() { public short getPassword() {
return field_2_password; return field_2_password;
} }
/** /**
* @returns byte representing the length of the username field * @return byte representing the length of the username field
*/ */
public short getUsernameLength() { public short getUsernameLength() {
return (short) field_3_username_value.length(); return (short) field_3_username_value.length();
} }
/** /**
* @returns username of the user that created the file * @return username of the user that created the file
*/ */
public String getUsername() { public String getUsername() {
return field_3_username_value; return field_3_username_value;

View File

@ -211,7 +211,7 @@ public final class HyperlinkRecord extends Record {
} }
/** /**
* Returns a 16-byte guid identifier. Seems to always equal {@link STD_MONIKER} * Returns a 16-byte guid identifier. Seems to always equal {@link #STD_MONIKER}
* *
* @return 16-byte guid identifier * @return 16-byte guid identifier
*/ */

View File

@ -523,7 +523,7 @@ public final class NameRecord extends Record {
* called by the constructor, should set class level fields. Should throw * called by the constructor, should set class level fields. Should throw
* runtime exception for bad/icomplete data. * runtime exception for bad/icomplete data.
* *
* @param in the RecordInputstream to read the record from * @param ris the RecordInputstream to read the record from
*/ */
public NameRecord(RecordInputStream ris) { public NameRecord(RecordInputStream ris) {
LittleEndianInput in = ris; LittleEndianInput in = ris;

View File

@ -40,8 +40,6 @@ public final class NoteStructureSubRecord extends SubRecord {
/** /**
* Construct a new <code>NoteStructureSubRecord</code> and * Construct a new <code>NoteStructureSubRecord</code> and
* fill its data with the default values * fill its data with the default values
* @param size
* @param in
*/ */
public NoteStructureSubRecord() public NoteStructureSubRecord()
{ {
@ -80,10 +78,7 @@ public final class NoteStructureSubRecord extends SubRecord {
/** /**
* Serialize the record data into the supplied array of bytes * Serialize the record data into the supplied array of bytes
* *
* @param offset offset in the <code>data</code> * @param out the stream to serialize into
* @param data the data to serialize into
*
* @return size of the record
*/ */
public void serialize(LittleEndianOutput out) { public void serialize(LittleEndianOutput out) {
out.writeShort(sid); out.writeShort(sid);

View File

@ -76,7 +76,7 @@ public final class RecordInputStream extends InputStream implements LittleEndian
} }
/** /**
* @returns the number of bytes available in the current BIFF record * @return the number of bytes available in the current BIFF record
* @see #remaining() * @see #remaining()
*/ */
public int available() { public int available() {
@ -216,7 +216,6 @@ public final class RecordInputStream extends InputStream implements LittleEndian
/** /**
* Reads a 16 bit, unsigned value. * Reads a 16 bit, unsigned value.
* @return
*/ */
public int readUShort() { public int readUShort() {
checkRecordPosition(LittleEndian.SHORT_SIZE); checkRecordPosition(LittleEndian.SHORT_SIZE);

View File

@ -94,7 +94,7 @@ public final class StyleRecord extends Record {
/** /**
* get the actual index of the style extended format record * get the actual index of the style extended format record
* @see #getIndex() * @see #getXFIndex()
* @return index of the xf record * @return index of the xf record
*/ */
public int getXFIndex() { public int getXFIndex() {

View File

@ -80,9 +80,7 @@ public final class SupBookRecord extends Record {
* called by the constructor, should set class level fields. Should throw * called by the constructor, should set class level fields. Should throw
* runtime exception for bad/incomplete data. * runtime exception for bad/incomplete data.
* *
* @param data raw data * @param in the stream to read from
* @param size size of data
* @param offset of the record's data (provided a big array of the file)
*/ */
public SupBookRecord(RecordInputStream in) { public SupBookRecord(RecordInputStream in) {
int recLen = in.remaining(); int recLen = in.remaining();

View File

@ -74,8 +74,7 @@ public final class CFRecordsAggregate extends RecordAggregate {
/** /**
* Create CFRecordsAggregate from a list of CF Records * Create CFRecordsAggregate from a list of CF Records
* @param recs - list of {@link Record} objects * @param rs - the stream to read from
* @param offset - position of {@link CFHeaderRecord} object in the list of Record objects
* @return CFRecordsAggregate object * @return CFRecordsAggregate object
*/ */
public static CFRecordsAggregate createCFAggregate(RecordStream rs) { public static CFRecordsAggregate createCFAggregate(RecordStream rs) {
@ -98,7 +97,6 @@ public final class CFRecordsAggregate extends RecordAggregate {
/** /**
* Create a deep clone of the record * Create a deep clone of the record
* @return
*/ */
public CFRecordsAggregate cloneCFAggregate() public CFRecordsAggregate cloneCFAggregate()
{ {

View File

@ -358,7 +358,7 @@ public final class RowRecordsAggregate extends RecordAggregate {
/** /**
* Create a row record. * Create a row record.
* *
* @param row number * @param rowNumber row number
* @return RowRecord created for the passed in row number * @return RowRecord created for the passed in row number
* @see org.apache.poi.hssf.record.RowRecord * @see org.apache.poi.hssf.record.RowRecord
*/ */

View File

@ -106,13 +106,6 @@ public final class SharedValueManager {
_groupsBySharedFormulaRecord = m; _groupsBySharedFormulaRecord = m;
} }
/**
* @param recs list of sheet records (possibly contains records for other parts of the Excel file)
* @param startIx index of first row/cell record for current sheet
* @param endIx one past index of last row/cell record for current sheet. It is important
* that this code does not inadvertently collect <tt>SharedFormulaRecord</tt>s from any other
* sheet (which could happen if endIx is chosen poorly). (see bug 44449)
*/
public static SharedValueManager create(SharedFormulaRecord[] sharedFormulaRecords, public static SharedValueManager create(SharedFormulaRecord[] sharedFormulaRecords,
ArrayRecord[] arrayRecords, TableRecord[] tableRecords) { ArrayRecord[] arrayRecords, TableRecord[] tableRecords) {
if (sharedFormulaRecords.length + arrayRecords.length + tableRecords.length < 1) { if (sharedFormulaRecords.length + arrayRecords.length + tableRecords.length < 1) {

View File

@ -321,7 +321,7 @@ public final class BorderFormatting {
/** /**
* get the color to use for the left border * get the color to use for the left border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public int getLeftBorderColor() { public int getLeftBorderColor() {
return bordLeftLineColor.getValue(field_13_border_styles1); return bordLeftLineColor.getValue(field_13_border_styles1);
@ -338,7 +338,7 @@ public final class BorderFormatting {
/** /**
* get the color to use for the right border * get the color to use for the right border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public int getRightBorderColor() { public int getRightBorderColor() {
return bordRightLineColor.getValue(field_13_border_styles1); return bordRightLineColor.getValue(field_13_border_styles1);
@ -355,7 +355,7 @@ public final class BorderFormatting {
/** /**
* get the color to use for the top border * get the color to use for the top border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public int getTopBorderColor() { public int getTopBorderColor() {
return bordTopLineColor.getValue(field_14_border_styles2); return bordTopLineColor.getValue(field_14_border_styles2);
@ -373,7 +373,7 @@ public final class BorderFormatting {
/** /**
* get the color to use for the bottom border * get the color to use for the bottom border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public int getBottomBorderColor() { public int getBottomBorderColor() {
return bordBottomLineColor.getValue(field_14_border_styles2); return bordBottomLineColor.getValue(field_14_border_styles2);
@ -390,7 +390,7 @@ public final class BorderFormatting {
/** /**
* get the color to use for the diagonal border * get the color to use for the diagonal border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public int getDiagonalBorderColor() { public int getDiagonalBorderColor() {
return bordDiagLineColor.getValue(field_14_border_styles2); return bordDiagLineColor.getValue(field_14_border_styles2);

View File

@ -89,7 +89,7 @@ public final class CellRangeUtil
* Do all possible cell merges between cells of the list so that:<br> * Do all possible cell merges between cells of the list so that:<br>
* <li>if a cell range is completely inside of another cell range, it gets removed from the list * <li>if a cell range is completely inside of another cell range, it gets removed from the list
* <li>if two cells have a shared border, merge them into one bigger cell range * <li>if two cells have a shared border, merge them into one bigger cell range
* @param cellRangeList * @param cellRanges
* @return updated List of cell ranges * @return updated List of cell ranges
*/ */
public static CellRangeAddress[] mergeCellRanges(CellRangeAddress[] cellRanges) { public static CellRangeAddress[] mergeCellRanges(CellRangeAddress[] cellRanges) {

View File

@ -188,8 +188,8 @@ public final class FontFormatting
/** /**
* set the font to be italics or not * set the font to be italics or not
* *
* @param italics - whether the font is italics or not * @param italic - whether the font is italics or not
* @see #setAttributes(short) * @see #setFontOption(boolean, org.apache.poi.util.BitField)
*/ */
public void setItalic(boolean italic) public void setItalic(boolean italic)
@ -201,7 +201,7 @@ public final class FontFormatting
* get whether the font is to be italics or not * get whether the font is to be italics or not
* *
* @return italics - whether the font is italics or not * @return italics - whether the font is italics or not
* @see #getAttributes() * @see #getFontOption(org.apache.poi.util.BitField)
*/ */
public boolean isItalic() public boolean isItalic()
@ -244,7 +244,7 @@ public final class FontFormatting
* get whether the font is to be stricken out or not * get whether the font is to be stricken out or not
* *
* @return strike - whether the font is stricken out or not * @return strike - whether the font is stricken out or not
* @see #getAttributes() * @see #getFontOption(org.apache.poi.util.BitField)
*/ */
public boolean isStruckout() public boolean isStruckout()

View File

@ -260,7 +260,7 @@ public abstract class Ptg implements Cloneable {
public abstract int getSize(); public abstract int getSize();
/** /**
* @return the encoded length of this Ptg, not including the initial Ptg type identifier byte. * //@return the encoded length of this Ptg, not including the initial Ptg type identifier byte.
*/ */
// public abstract int getDataSize(); // public abstract int getDataSize();

View File

@ -234,7 +234,7 @@ public final class OperandResolver {
* "5**2" -&gt; 500<br/> * "5**2" -&gt; 500<br/>
* "250%" -&gt; 2.5<br/> * "250%" -&gt; 2.5<br/>
* *
* @param text * @param pText
* @return <code>null</code> if the specified text cannot be parsed as a number * @return <code>null</code> if the specified text cannot be parsed as a number
*/ */
public static Double parseDouble(String pText) { public static Double parseDouble(String pText) {

View File

@ -90,7 +90,7 @@ public abstract class TextFunction implements Function {
* An implementation of the TRIM function: * An implementation of the TRIM function:
* Removes leading and trailing spaces from value if evaluated operand * Removes leading and trailing spaces from value if evaluated operand
* value is string. * value is string.
* @author Manda Wilson &lt; wilson at c bio dot msk cc dot org &gt; * Author: Manda Wilson &lt; wilson at c bio dot msk cc dot org &gt;
*/ */
public static final Function TRIM = new SingleArgTextFunc() { public static final Function TRIM = new SingleArgTextFunc() {
protected ValueEval evaluate(String arg) { protected ValueEval evaluate(String arg) {
@ -106,7 +106,7 @@ public abstract class TextFunction implements Function {
* <b>Syntax<b>:<br/> <b>MID</b>(<b>text</b>, <b>start_num</b>, * <b>Syntax<b>:<br/> <b>MID</b>(<b>text</b>, <b>start_num</b>,
* <b>num_chars</b>)<br/> * <b>num_chars</b>)<br/>
* *
* @author Manda Wilson &lt; wilson at c bio dot msk cc dot org &gt; * Author: Manda Wilson &lt; wilson at c bio dot msk cc dot org &gt;
*/ */
public static final Function MID = new TextFunction() { public static final Function MID = new TextFunction() {

View File

@ -216,7 +216,6 @@ public class HSSFCell implements Cell {
/** /**
* Returns the Workbook that this Cell is bound to * Returns the Workbook that this Cell is bound to
* @return
*/ */
protected Workbook getBoundWorkbook() { protected Workbook getBoundWorkbook() {
return book.getWorkbook(); return book.getWorkbook();
@ -1085,7 +1084,7 @@ public class HSSFCell implements Cell {
/** /**
* Assign a hypelrink to this cell * Assign a hypelrink to this cell
* *
* @param link hypelrink associated with this cell * @param hyperlink hypelrink associated with this cell
*/ */
public void setHyperlink(Hyperlink hyperlink){ public void setHyperlink(Hyperlink hyperlink){
HSSFHyperlink link = (HSSFHyperlink)hyperlink; HSSFHyperlink link = (HSSFHyperlink)hyperlink;

View File

@ -437,28 +437,6 @@ public class HSSFCellStyle implements CellStyle
return format.getAlignment(); return format.getAlignment();
} }
/**
* get whether this cell is to be part of a merged block of cells
*
* @returns merged or not
*/
// public boolean getMergeCells()
// {
// return format.getMergeCells();
// }
/**
* set whether this cell is to be part of a merged block of cells
*
* @param merge merged or not
*/
// public void setMergeCells(boolean merge)
// {
// format.setMergeCells(merge);
// }
/** /**
* set whether the text should be wrapped * set whether the text should be wrapped
* @param wrapped wrap text or not * @param wrapped wrap text or not
@ -767,7 +745,7 @@ public class HSSFCellStyle implements CellStyle
/** /**
* get the color to use for the left border * get the color to use for the left border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public short getLeftBorderColor() public short getLeftBorderColor()
{ {
@ -786,7 +764,7 @@ public class HSSFCellStyle implements CellStyle
/** /**
* get the color to use for the left border * get the color to use for the left border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public short getRightBorderColor() public short getRightBorderColor()
{ {
@ -805,7 +783,7 @@ public class HSSFCellStyle implements CellStyle
/** /**
* get the color to use for the top border * get the color to use for the top border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public short getTopBorderColor() public short getTopBorderColor()
{ {
@ -824,7 +802,7 @@ public class HSSFCellStyle implements CellStyle
/** /**
* get the color to use for the left border * get the color to use for the left border
* @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short) * @see org.apache.poi.hssf.usermodel.HSSFPalette#getColor(short)
* @param color The index of the color definition * @return The index of the color definition
*/ */
public short getBottomBorderColor() public short getBottomBorderColor()
{ {

View File

@ -43,7 +43,7 @@ import org.apache.poi.ss.util.Region;
* </LI> * </LI>
* </UL> * </UL>
* *
* Use {@link HSSFSheet#getConditionalFormattingAt(int)} to get access to an instance of this class. * Use {@link org.apache.poi.hssf.usermodel.HSSFSheet#getSheetConditionalFormatting()} to get access to an instance of this class.
* <P> * <P>
* To create a new Conditional Formatting set use the following approach: * To create a new Conditional Formatting set use the following approach:
* *

View File

@ -138,7 +138,7 @@ public final class HSSFDataValidation {
} }
/** /**
* @param show <code>true</code> if an prompt box should be displayed , <code>false</code> otherwise * @return <code>true</code> if an prompt box should be displayed , <code>false</code> otherwise
*/ */
public boolean getShowPromptBox() { public boolean getShowPromptBox() {
return _showPromptBox; return _showPromptBox;

View File

@ -102,7 +102,6 @@ public final class HSSFFontFormatting
} }
/** /**
* @return
* @see org.apache.poi.hssf.record.cf.FontFormatting#getRawRecord() * @see org.apache.poi.hssf.record.cf.FontFormatting#getRawRecord()
*/ */
protected byte[] getRawRecord() protected byte[] getRawRecord()
@ -228,7 +227,7 @@ public final class HSSFFontFormatting
* set font style options. * set font style options.
* *
* @param italic - if true, set posture style to italic, otherwise to normal * @param italic - if true, set posture style to italic, otherwise to normal
* @param bold- if true, set font weight to bold, otherwise to normal * @param bold if true, set font weight to bold, otherwise to normal
*/ */
public void setFontStyle(boolean italic, boolean bold) public void setFontStyle(boolean italic, boolean bold)
@ -302,7 +301,7 @@ public final class HSSFFontFormatting
/** /**
* @param height * @param height
* @see org.apache.poi.hssf.record.cf.FontFormatting#setFontHeight(short) * @see org.apache.poi.hssf.record.cf.FontFormatting#setFontHeight(int)
*/ */
public void setFontHeight(int height) public void setFontHeight(int height)
{ {
@ -369,7 +368,7 @@ public final class HSSFFontFormatting
/** /**
* set the type of underlining type for the font * set the type of underlining type for the font
* *
* @param u super or subscript option * @param underlineType super or subscript option
* *
* @see #U_NONE * @see #U_NONE
* @see #U_SINGLE * @see #U_SINGLE

View File

@ -33,7 +33,7 @@ import org.apache.poi.ss.usermodel.CellValue;
* Evaluates formula cells.<p/> * Evaluates formula cells.<p/>
* *
* For performance reasons, this class keeps a cache of all previously calculated intermediate * For performance reasons, this class keeps a cache of all previously calculated intermediate
* cell values. Be sure to call {@link #clearCache()} if any workbook cells are changed between * cell values. Be sure to call {@link #clearAllCachedResultValues()} if any workbook cells are changed between
* calls to evaluate~ methods on this class. * calls to evaluate~ methods on this class.
* *
* @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
@ -156,7 +156,7 @@ public class HSSFFormulaEvaluator /* almost implements FormulaEvaluator */ {
* int evaluatedCellType = evaluator.evaluateFormulaCell(cell); * int evaluatedCellType = evaluator.evaluateFormulaCell(cell);
* </pre> * </pre>
* Be aware that your cell will hold both the formula, and the result. If you want the cell * Be aware that your cell will hold both the formula, and the result. If you want the cell
* replaced with the result of the formula, use {@link #evaluateInCell(HSSFCell)} * replaced with the result of the formula, use {@link #evaluateInCell(org.apache.poi.ss.usermodel.Cell)}
* @param cell The cell to evaluate * @param cell The cell to evaluate
* @return -1 for non-formula cells, or the type of the <em>formula result</em> * @return -1 for non-formula cells, or the type of the <em>formula result</em>
*/ */
@ -183,7 +183,7 @@ public class HSSFFormulaEvaluator /* almost implements FormulaEvaluator */ {
* </pre> * </pre>
* Be aware that your cell value will be changed to hold the * Be aware that your cell value will be changed to hold the
* result of the formula. If you simply want the formula * result of the formula. If you simply want the formula
* value computed for you, use {@link #evaluateFormulaCell(HSSFCell)} * value computed for you, use {@link #evaluateFormulaCell(org.apache.poi.ss.usermodel.Cell)}}
* @param cell * @param cell
*/ */
public HSSFCell evaluateInCell(Cell cell) { public HSSFCell evaluateInCell(Cell cell) {

View File

@ -82,7 +82,6 @@ public class HSSFPatternFormatting
} }
/** /**
* @return
* @see org.apache.poi.hssf.record.cf.PatternFormatting#getFillBackgroundColor() * @see org.apache.poi.hssf.record.cf.PatternFormatting#getFillBackgroundColor()
*/ */
public short getFillBackgroundColor() public short getFillBackgroundColor()
@ -91,7 +90,6 @@ public class HSSFPatternFormatting
} }
/** /**
* @return
* @see org.apache.poi.hssf.record.cf.PatternFormatting#getFillForegroundColor() * @see org.apache.poi.hssf.record.cf.PatternFormatting#getFillForegroundColor()
*/ */
public short getFillForegroundColor() public short getFillForegroundColor()
@ -100,7 +98,6 @@ public class HSSFPatternFormatting
} }
/** /**
* @return
* @see org.apache.poi.hssf.record.cf.PatternFormatting#getFillPattern() * @see org.apache.poi.hssf.record.cf.PatternFormatting#getFillPattern()
*/ */
public short getFillPattern() public short getFillPattern()
@ -110,7 +107,7 @@ public class HSSFPatternFormatting
/** /**
* @param bg * @param bg
* @see org.apache.poi.hssf.record.cf.PatternFormatting#setFillBackgroundColor(short) * @see org.apache.poi.hssf.record.cf.PatternFormatting#setFillBackgroundColor(int)
*/ */
public void setFillBackgroundColor(short bg) public void setFillBackgroundColor(short bg)
{ {
@ -123,7 +120,7 @@ public class HSSFPatternFormatting
/** /**
* @param fg * @param fg
* @see org.apache.poi.hssf.record.cf.PatternFormatting#setFillForegroundColor(short) * @see org.apache.poi.hssf.record.cf.PatternFormatting#setFillForegroundColor(int)
*/ */
public void setFillForegroundColor(short fg) public void setFillForegroundColor(short fg)
{ {
@ -136,7 +133,7 @@ public class HSSFPatternFormatting
/** /**
* @param fp * @param fp
* @see org.apache.poi.hssf.record.cf.PatternFormatting#setFillPattern(short) * @see org.apache.poi.hssf.record.cf.PatternFormatting#setFillPattern(int)
*/ */
public void setFillPattern(short fp) public void setFillPattern(short fp)
{ {

View File

@ -317,7 +317,7 @@ public final class HSSFRow implements Comparable, Row {
* Get the hssfcell representing a given column (logical cell) * Get the hssfcell representing a given column (logical cell)
* 0-based. If you ask for a cell that is not defined then * 0-based. If you ask for a cell that is not defined then
* you get a null, unless you have set a different * you get a null, unless you have set a different
* {@link MissingCellPolicy} on the base workbook. * {@link org.apache.poi.ss.usermodel.Row.MissingCellPolicy} on the base workbook.
* *
* @param cellnum 0 based column number * @param cellnum 0 based column number
* @return HSSFCell representing that column or null if undefined. * @return HSSFCell representing that column or null if undefined.
@ -560,7 +560,7 @@ public final class HSSFRow implements Comparable, Row {
* will not return un-defined (null) cells. * will not return un-defined (null) cells.
* Call getCellNum() on the returned cells to know which cell they are. * Call getCellNum() on the returned cells to know which cell they are.
* As this only ever works on physically defined cells, * As this only ever works on physically defined cells,
* the {@link MissingCellPolicy} has no effect. * the {@link org.apache.poi.ss.usermodel.Row.MissingCellPolicy} has no effect.
*/ */
public Iterator cellIterator() public Iterator cellIterator()
{ {

View File

@ -201,7 +201,7 @@ public class HSSFSheet implements org.apache.poi.ss.usermodel.Sheet
* @param rownum row number * @param rownum row number
* @return High level HSSFRow object representing a row in the sheet * @return High level HSSFRow object representing a row in the sheet
* @see org.apache.poi.hssf.usermodel.HSSFRow * @see org.apache.poi.hssf.usermodel.HSSFRow
* @see #removeRow(HSSFRow) * @see #removeRow(org.apache.poi.ss.usermodel.Row)
*/ */
public HSSFRow createRow(int rownum) public HSSFRow createRow(int rownum)
{ {

View File

@ -45,7 +45,7 @@ public final class HSSFSheetConditionalFormatting {
* TODO - formulas containing cell references are currently not parsed properly * TODO - formulas containing cell references are currently not parsed properly
* *
* @param comparisonOperation - a constant value from * @param comparisonOperation - a constant value from
* <tt>{@link HSSFConditionalFormattingRule.ComparisonOperator}</tt>: <p> * <tt>{@link org.apache.poi.hssf.record.CFRuleRecord.ComparisonOperator}</tt>: <p>
* <ul> * <ul>
* <li>BETWEEN</li> * <li>BETWEEN</li>
* <li>NOT_BETWEEN</li> * <li>NOT_BETWEEN</li>
@ -59,8 +59,8 @@ public final class HSSFSheetConditionalFormatting {
* </p> * </p>
* @param formula1 - formula for the valued, compared with the cell * @param formula1 - formula for the valued, compared with the cell
* @param formula2 - second formula (only used with * @param formula2 - second formula (only used with
* {@link HSSFConditionalFormattingRule#COMPARISON_OPERATOR_BETWEEN}) and * {@link org.apache.poi.hssf.record.CFRuleRecord.ComparisonOperator#BETWEEN}) and
* {@link HSSFConditionalFormattingRule#COMPARISON_OPERATOR_NOT_BETWEEN} operations) * {@link org.apache.poi.hssf.record.CFRuleRecord.ComparisonOperator#NOT_BETWEEN} operations)
*/ */
public HSSFConditionalFormattingRule createConditionalFormattingRule( public HSSFConditionalFormattingRule createConditionalFormattingRule(
byte comparisonOperation, byte comparisonOperation,

View File

@ -382,7 +382,7 @@ public class HSSFWorkbook extends POIDocument implements org.apache.poi.ss.userm
* Sets the policy on what to do when * Sets the policy on what to do when
* getting missing or blank cells from a row. * getting missing or blank cells from a row.
* This will then apply to all calls to * This will then apply to all calls to
* {@link HSSFRow.getCell()}. See * {@link HSSFRow#getCell(int)}}. See
* {@link MissingCellPolicy}. * {@link MissingCellPolicy}.
* Note that this has no effect on any * Note that this has no effect on any
* iterators, only on when fetching Cells * iterators, only on when fetching Cells

View File

@ -21,7 +21,7 @@ package org.apache.poi.ss.formula;
* Abstracts a cell for the purpose of formula evaluation. This interface represents both formula * Abstracts a cell for the purpose of formula evaluation. This interface represents both formula
* and non-formula cells.<br/> * and non-formula cells.<br/>
* *
* Implementors of this class must implement {@link #hashCode()} and {@link #equals(Object)} * Implementors of this class must implement {@link Object#hashCode()} and {@link Object#equals(Object)}
* to provide an <em>identity</em> relationship based on the underlying HSSF or XSSF cell <p/> * to provide an <em>identity</em> relationship based on the underlying HSSF or XSSF cell <p/>
* *
* For POI internal use only * For POI internal use only

View File

@ -18,7 +18,7 @@
package org.apache.poi.ss.formula; package org.apache.poi.ss.formula;
/** /**
* Should be implemented by any {@link Ptg} subclass that needs has an extern sheet index <br/> * Should be implemented by any {@link org.apache.poi.hssf.record.formula.Ptg} subclass that needs has an extern sheet index <br/>
* *
* For POI internal use only * For POI internal use only
* *

View File

@ -18,7 +18,7 @@
package org.apache.poi.ss.formula; package org.apache.poi.ss.formula;
/** /**
* Should be implemented by any {@link Ptg} subclass that needs a workbook to render its formula. * Should be implemented by any {@link org.apache.poi.hssf.record.formula.Ptg} subclass that needs a workbook to render its formula.
* <br/> * <br/>
* *
* For POI internal use only * For POI internal use only

View File

@ -68,7 +68,7 @@ import org.apache.poi.ss.usermodel.Cell;
* Evaluates formula cells.<p/> * Evaluates formula cells.<p/>
* *
* For performance reasons, this class keeps a cache of all previously calculated intermediate * For performance reasons, this class keeps a cache of all previously calculated intermediate
* cell values. Be sure to call {@link #clearCache()} if any workbook cells are changed between * cell values. Be sure to call {@link #clearAllCachedResultValues()} if any workbook cells are changed between
* calls to evaluate~ methods on this class.<br/> * calls to evaluate~ methods on this class.<br/>
* *
* For POI internal use only * For POI internal use only

View File

@ -17,20 +17,11 @@
package org.apache.poi.ss.usermodel; package org.apache.poi.ss.usermodel;
import org.apache.poi.hssf.record.formula.eval.BlankEval;
import org.apache.poi.hssf.record.formula.eval.BoolEval;
import org.apache.poi.hssf.record.formula.eval.ErrorEval;
import org.apache.poi.hssf.record.formula.eval.NumberEval;
import org.apache.poi.hssf.record.formula.eval.StringEval;
import org.apache.poi.hssf.record.formula.eval.ValueEval;
import org.apache.poi.hssf.usermodel.HSSFSheet;
/** /**
* Evaluates formula cells.<p/> * Evaluates formula cells.<p/>
* *
* For performance reasons, this class keeps a cache of all previously calculated intermediate * For performance reasons, this class keeps a cache of all previously calculated intermediate
* cell values. Be sure to call {@link #clearCache()} if any workbook cells are changed between * cell values. Be sure to call {@link #clearAllCachedResultValues()} if any workbook cells are changed between
* calls to evaluate~ methods on this class. * calls to evaluate~ methods on this class.
* *
* @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;

View File

@ -17,8 +17,8 @@
package org.apache.poi.ss.usermodel; package org.apache.poi.ss.usermodel;
/** /**
* Common interface for {@link Header} and * Common interface for {@link org.apache.poi.ss.usermodel.Header} and
* {@link Footer}. * {@link org.apache.poi.ss.usermodel.Footer}.
*/ */
public interface HeaderFooter { public interface HeaderFooter {
/** /**

View File

@ -101,28 +101,28 @@ public abstract class CellRangeAddressBase {
} }
/** /**
* @param _firstCol column number for the upper left hand corner * @param firstCol column number for the upper left hand corner
*/ */
public final void setFirstColumn(int firstCol) { public final void setFirstColumn(int firstCol) {
_firstCol = firstCol; _firstCol = firstCol;
} }
/** /**
* @param rowFrom row number for the upper left hand corner * @param firstRow row number for the upper left hand corner
*/ */
public final void setFirstRow(int firstRow) { public final void setFirstRow(int firstRow) {
_firstRow = firstRow; _firstRow = firstRow;
} }
/** /**
* @param colTo column number for the lower right hand corner * @param lastCol column number for the lower right hand corner
*/ */
public final void setLastColumn(int lastCol) { public final void setLastColumn(int lastCol) {
_lastCol = lastCol; _lastCol = lastCol;
} }
/** /**
* @param rowTo row number for the lower right hand corner * @param lastRow row number for the lower right hand corner
*/ */
public final void setLastRow(int lastRow) { public final void setLastRow(int lastRow) {
_lastRow = lastRow; _lastRow = lastRow;

View File

@ -84,7 +84,6 @@ public class CellRangeAddressList {
* @param firstCol - the upper left hand corner's col * @param firstCol - the upper left hand corner's col
* @param lastRow - the lower right hand corner's row * @param lastRow - the lower right hand corner's row
* @param lastCol - the lower right hand corner's col * @param lastCol - the lower right hand corner's col
* @return the index of this ADDR structure
*/ */
public void addCellRangeAddress(int firstRow, int firstCol, int lastRow, int lastCol) { public void addCellRangeAddress(int firstRow, int firstCol, int lastRow, int lastCol) {
CellRangeAddress region = new CellRangeAddress(firstRow, lastRow, firstCol, lastCol); CellRangeAddress region = new CellRangeAddress(firstRow, lastRow, firstCol, lastCol);

View File

@ -209,7 +209,7 @@ public class Region implements Comparable {
/** /**
* Convert a List of CellRange objects to an array of regions * Convert a List of CellRange objects to an array of regions
* *
* @param List of CellRange objects * @param cellRanges list of CellRange objects
* @return regions * @return regions
*/ */
public static Region[] convertCellRangesToRegions(CellRangeAddress[] cellRanges) { public static Region[] convertCellRangesToRegions(CellRangeAddress[] cellRanges) {

View File

@ -25,7 +25,7 @@ import org.apache.poi.hssf.record.RecordInputStream;
/** /**
* Title: String Utility Description: Collection of string handling utilities<p/> * Title: String Utility Description: Collection of string handling utilities<p/>
* *
* Note - none of the methods in this class deals with {@link ContinueRecord}s. For such * Note - none of the methods in this class deals with {@link org.apache.poi.hssf.record.ContinueRecord}s. For such
* functionality, consider using {@link RecordInputStream * functionality, consider using {@link RecordInputStream
} * } *
* *

View File

@ -84,9 +84,7 @@ public class PackageHelper {
} }
/** /**
* * Creates an empty file in the default temporary-file directory,
* @return
* @throws IOException
*/ */
public static File createTempFile() throws IOException { public static File createTempFile() throws IOException {
File file = File.createTempFile("poi-ooxml-", ".tmp"); File file = File.createTempFile("poi-ooxml-", ".tmp");

View File

@ -36,7 +36,7 @@ public interface XSSFChildContainingModel extends XSSFModel {
* appropriate model or usermodel thing can be * appropriate model or usermodel thing can be
* created for it. * created for it.
* @param childPart The PackagePart of the child * @param childPart The PackagePart of the child
* @param childId the ID of the relationship the child comes from * @param childRelId the ID of the relationship the child comes from
*/ */
public void generateChild(PackagePart childPart, String childRelId); public void generateChild(PackagePart childPart, String childRelId);

View File

@ -86,8 +86,8 @@ public final class XSSFCell implements Cell {
/** /**
* Construct a XSSFCell. * Construct a XSSFCell.
* *
* @param row the xml bean containing information about the cell.
* @param row the parent row. * @param row the parent row.
* @param cell the xml bean containing information about the cell.
*/ */
protected XSSFCell(XSSFRow row, CTCell cell) { protected XSSFCell(XSSFRow row, CTCell cell) {
this.cell = cell; this.cell = cell;

View File

@ -120,13 +120,13 @@ public class XSSFCellStyle implements CellStyle {
* Get the type of horizontal alignment for the cell * Get the type of horizontal alignment for the cell
* *
* @return short - the type of alignment * @return short - the type of alignment
* @see #ALIGN_GENERAL * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_GENERAL
* @see #ALIGN_LEFT * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_LEFT
* @see #ALIGN_CENTER * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_CENTER
* @see #ALIGN_RIGHT * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_RIGHT
* @see #ALIGN_FILL * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_FILL
* @see #ALIGN_JUSTIFY * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_JUSTIFY
* @see #ALIGN_CENTER_SELECTION * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_CENTER_SELECTION
*/ */
public short getAlignment() { public short getAlignment() {
return (short)(getAlignmentEnum().ordinal()); return (short)(getAlignmentEnum().ordinal());
@ -136,6 +136,7 @@ public class XSSFCellStyle implements CellStyle {
* Get the type of horizontal alignment for the cell * Get the type of horizontal alignment for the cell
* *
* @return HorizontalAlignment - the type of alignment * @return HorizontalAlignment - the type of alignment
* @see org.apache.poi.ss.usermodel.HorizontalAlignment
*/ */
public HorizontalAlignment getAlignmentEnum() { public HorizontalAlignment getAlignmentEnum() {
CTCellAlignment align = cellXf.getAlignment(); CTCellAlignment align = cellXf.getAlignment();
@ -150,20 +151,20 @@ public class XSSFCellStyle implements CellStyle {
* Get the type of border to use for the bottom border of the cell * Get the type of border to use for the bottom border of the cell
* *
* @return short - border type * @return short - border type
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public short getBorderBottom() { public short getBorderBottom() {
if(!cellXf.getApplyBorder()) return BORDER_NONE; if(!cellXf.getApplyBorder()) return BORDER_NONE;
@ -188,21 +189,21 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of border to use for the left border of the cell * Get the type of border to use for the left border of the cell
* *
* @return short - border type, default value is {@link #BORDER_NONE} * @return short - border type, default value is {@link org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE}
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public short getBorderLeft() { public short getBorderLeft() {
if(!cellXf.getApplyBorder()) return BORDER_NONE; if(!cellXf.getApplyBorder()) return BORDER_NONE;
@ -216,7 +217,7 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of border to use for the left border of the cell * Get the type of border to use for the left border of the cell
* *
* @return border type, default value is {@link BorderStyle.NONE} * @return border type, default value is {@link org.apache.poi.ss.usermodel.BorderStyle#NONE}
*/ */
public BorderStyle getBorderLeftEnum() { public BorderStyle getBorderLeftEnum() {
int style = getBorderLeft(); int style = getBorderLeft();
@ -226,21 +227,21 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of border to use for the right border of the cell * Get the type of border to use for the right border of the cell
* *
* @return short - border type, default value is {@link #BORDER_NONE} * @return short - border type, default value is {@link org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE}
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public short getBorderRight() { public short getBorderRight() {
if(!cellXf.getApplyBorder()) return BORDER_NONE; if(!cellXf.getApplyBorder()) return BORDER_NONE;
@ -254,7 +255,7 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of border to use for the right border of the cell * Get the type of border to use for the right border of the cell
* *
* @return border type, default value is {@link BorderStyle.NONE} * @return border type, default value is {@link org.apache.poi.ss.usermodel.BorderStyle#NONE}
*/ */
public BorderStyle getBorderRightEnum() { public BorderStyle getBorderRightEnum() {
int style = getBorderRight(); int style = getBorderRight();
@ -264,21 +265,21 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of border to use for the top border of the cell * Get the type of border to use for the top border of the cell
* *
* @return short - border type, default value is {@link #BORDER_NONE} * @return short - border type, default value is {@link org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE}
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle #BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public short getBorderTop() { public short getBorderTop() {
if(!cellXf.getApplyBorder()) return BORDER_NONE; if(!cellXf.getApplyBorder()) return BORDER_NONE;
@ -292,7 +293,7 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of border to use for the top border of the cell * Get the type of border to use for the top border of the cell
* *
* @return border type, default value is {@link BorderStyle.NONE} * @return border type, default value is {@link org.apache.poi.ss.usermodel.BorderStyle#NONE}
*/ */
public BorderStyle getBorderTopEnum() { public BorderStyle getBorderTopEnum() {
int style = getBorderTop(); int style = getBorderTop();
@ -303,8 +304,8 @@ public class XSSFCellStyle implements CellStyle {
* Get the color to use for the bottom border * Get the color to use for the bottom border
* <br/> * <br/>
* Color is optional. When missing, IndexedColors.AUTOMATIC is implied. * Color is optional. When missing, IndexedColors.AUTOMATIC is implied.
* @return the index of the color definition, default value is {@link org.apache.poi.ss.usermodel.IndexedColors.AUTOMATIC} * @return the index of the color definition, default value is {@link org.apache.poi.ss.usermodel.IndexedColors#AUTOMATIC}
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public short getBottomBorderColor() { public short getBottomBorderColor() {
XSSFColor clr = getBottomBorderXSSFColor(); XSSFColor clr = getBottomBorderXSSFColor();
@ -350,8 +351,8 @@ public class XSSFCellStyle implements CellStyle {
* Note - many cells are actually filled with a foreground * Note - many cells are actually filled with a foreground
* fill, not a background fill - see {@link #getFillForegroundColor()} * fill, not a background fill - see {@link #getFillForegroundColor()}
* </p> * </p>
* @return fill color, default value is {@link IndexedColors.AUTOMATIC} * @return fill color, default value is {@link org.apache.poi.ss.usermodel.IndexedColors#AUTOMATIC}
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public short getFillBackgroundColor() { public short getFillBackgroundColor() {
XSSFColor clr = getFillBackgroundXSSFColor(); XSSFColor clr = getFillBackgroundXSSFColor();
@ -383,7 +384,7 @@ public class XSSFCellStyle implements CellStyle {
* background color ({@link #getFillBackgroundColor()}) * background color ({@link #getFillBackgroundColor()})
* </p> * </p>
* @see IndexedColors * @see IndexedColors
* @return fill color, default value is {@link IndexedColors.AUTOMATIC} * @return fill color, default value is {@link org.apache.poi.ss.usermodel.IndexedColors#AUTOMATIC}
*/ */
public short getFillForegroundColor() { public short getFillForegroundColor() {
XSSFColor clr = getFillForegroundXSSFColor(); XSSFColor clr = getFillForegroundXSSFColor();
@ -406,25 +407,25 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the fill pattern * Get the fill pattern
* @return fill pattern, default value is {@link #NO_FILL} * @return fill pattern, default value is {@link org.apache.poi.ss.usermodel.CellStyle#NO_FILL}
* *
* @see #NO_FILL * @see org.apache.poi.ss.usermodel.CellStyle#NO_FILL
* @see #SOLID_FOREGROUND * @see org.apache.poi.ss.usermodel.CellStyle#SOLID_FOREGROUND
* @see #FINE_DOTS * @see org.apache.poi.ss.usermodel.CellStyle#FINE_DOTS
* @see #ALT_BARS * @see org.apache.poi.ss.usermodel.CellStyle#ALT_BARS
* @see #SPARSE_DOTS * @see org.apache.poi.ss.usermodel.CellStyle#SPARSE_DOTS
* @see #THICK_HORZ_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THICK_HORZ_BANDS
* @see #THICK_VERT_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THICK_VERT_BANDS
* @see #THICK_BACKWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THICK_BACKWARD_DIAG
* @see #THICK_FORWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THICK_FORWARD_DIAG
* @see #BIG_SPOTS * @see org.apache.poi.ss.usermodel.CellStyle#BIG_SPOTS
* @see #BRICKS * @see org.apache.poi.ss.usermodel.CellStyle#BRICKS
* @see #THIN_HORZ_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THIN_HORZ_BANDS
* @see #THIN_VERT_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THIN_VERT_BANDS
* @see #THIN_BACKWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THIN_BACKWARD_DIAG
* @see #THIN_FORWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THIN_FORWARD_DIAG
* @see #SQUARES * @see org.apache.poi.ss.usermodel.CellStyle#SQUARES
* @see #DIAMONDS * @see org.apache.poi.ss.usermodel.CellStyle#DIAMONDS
*/ */
public short getFillPattern() { public short getFillPattern() {
if(!cellXf.getApplyFill()) return 0; if(!cellXf.getApplyFill()) return 0;
@ -440,7 +441,7 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the fill pattern * Get the fill pattern
* *
* @return the fill pattern, default value is {@link FillPatternType.NO_FILL} * @return the fill pattern, default value is {@link org.apache.poi.ss.usermodel.FillPatternType#NO_FILL}
*/ */
public FillPatternType getFillPatternEnum() { public FillPatternType getFillPatternEnum() {
int style = getFillPattern(); int style = getFillPattern();
@ -499,8 +500,8 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the color to use for the left border * Get the color to use for the left border
* *
* @return the index of the color definition, default value is {@link IndexedColors.BLACK} * @return the index of the color definition, default value is {@link org.apache.poi.ss.usermodel.IndexedColors#BLACK}
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public short getLeftBorderColor() { public short getLeftBorderColor() {
XSSFColor clr = getLeftBorderXSSFColor(); XSSFColor clr = getLeftBorderXSSFColor();
@ -511,7 +512,7 @@ public class XSSFCellStyle implements CellStyle {
* Get the color to use for the left border * Get the color to use for the left border
* *
* @return the index of the color definition or <code>null</code> if not set * @return the index of the color definition or <code>null</code> if not set
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public XSSFColor getLeftBorderXSSFColor() { public XSSFColor getLeftBorderXSSFColor() {
if(!cellXf.getApplyBorder()) return null; if(!cellXf.getApplyBorder()) return null;
@ -534,8 +535,8 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the color to use for the right border * Get the color to use for the right border
* *
* @return the index of the color definition, default value is {@link IndexedColors.BLACK} * @return the index of the color definition, default value is {@link org.apache.poi.ss.usermodel.IndexedColors#BLACK}
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public short getRightBorderColor() { public short getRightBorderColor() {
XSSFColor clr = getRightBorderXSSFColor(); XSSFColor clr = getRightBorderXSSFColor();
@ -577,8 +578,8 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the color to use for the top border * Get the color to use for the top border
* *
* @return the index of the color definition, default value is {@link IndexedColors.BLACK} * @return the index of the color definition, default value is {@link org.apache.poi.ss.usermodel.IndexedColors#BLACK}
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public short getTopBorderColor() { public short getTopBorderColor() {
XSSFColor clr = getTopBorderXSSFColor(); XSSFColor clr = getTopBorderXSSFColor();
@ -602,11 +603,11 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of vertical alignment for the cell * Get the type of vertical alignment for the cell
* *
* @return align the type of alignment, default value is {@link #VERTICAL_BOTTOM} * @return align the type of alignment, default value is {@link org.apache.poi.ss.usermodel.CellStyle#VERTICAL_BOTTOM}
* @see #VERTICAL_TOP * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_TOP
* @see #VERTICAL_CENTER * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_CENTER
* @see #VERTICAL_BOTTOM * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_BOTTOM
* @see #VERTICAL_JUSTIFY * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_JUSTIFY
*/ */
public short getVerticalAlignment() { public short getVerticalAlignment() {
return (short) (getVerticalAlignmentEnum().ordinal()); return (short) (getVerticalAlignmentEnum().ordinal());
@ -615,8 +616,8 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Get the type of vertical alignment for the cell * Get the type of vertical alignment for the cell
* *
* @return the type of alignment, default value is {@link VerticalAlignment.BOTTOM} * @return the type of alignment, default value is {@link org.apache.poi.ss.usermodel.VerticalAlignment#BOTTOM}
* @see VerticalAlignment * @see org.apache.poi.ss.usermodel.VerticalAlignment
*/ */
public VerticalAlignment getVerticalAlignmentEnum() { public VerticalAlignment getVerticalAlignmentEnum() {
CTCellAlignment align = cellXf.getAlignment(); CTCellAlignment align = cellXf.getAlignment();
@ -641,13 +642,13 @@ public class XSSFCellStyle implements CellStyle {
* Set the type of horizontal alignment for the cell * Set the type of horizontal alignment for the cell
* *
* @param align - the type of alignment * @param align - the type of alignment
* @see #ALIGN_GENERAL * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_GENERAL
* @see #ALIGN_LEFT * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_LEFT
* @see #ALIGN_CENTER * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_CENTER
* @see #ALIGN_RIGHT * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_RIGHT
* @see #ALIGN_FILL * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_FILL
* @see #ALIGN_JUSTIFY * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_JUSTIFY
* @see #ALIGN_CENTER_SELECTION * @see org.apache.poi.ss.usermodel.CellStyle#ALIGN_CENTER_SELECTION
*/ */
public void setAlignment(short align) { public void setAlignment(short align) {
getCellAlignment().setHorizontal(HorizontalAlignment.values()[align]); getCellAlignment().setHorizontal(HorizontalAlignment.values()[align]);
@ -667,20 +668,20 @@ public class XSSFCellStyle implements CellStyle {
* Set the type of border to use for the bottom border of the cell * Set the type of border to use for the bottom border of the cell
* *
* @param border the type of border to use * @param border the type of border to use
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public void setBorderBottom(short border) { public void setBorderBottom(short border) {
CTBorder ct = getCTBorder(); CTBorder ct = getCTBorder();
@ -698,7 +699,7 @@ public class XSSFCellStyle implements CellStyle {
* Set the type of border to use for the bottom border of the cell * Set the type of border to use for the bottom border of the cell
* *
* @param border - type of border to use * @param border - type of border to use
* @see BorderStyle * @see org.apache.poi.ss.usermodel.BorderStyle
*/ */
public void setBorderBottom(BorderStyle border) { public void setBorderBottom(BorderStyle border) {
setBorderBottom((short)border.ordinal()); setBorderBottom((short)border.ordinal());
@ -707,20 +708,20 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Set the type of border to use for the left border of the cell * Set the type of border to use for the left border of the cell
* @param border the type of border to use * @param border the type of border to use
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public void setBorderLeft(short border) { public void setBorderLeft(short border) {
CTBorder ct = getCTBorder(); CTBorder ct = getCTBorder();
@ -747,20 +748,20 @@ public class XSSFCellStyle implements CellStyle {
* Set the type of border to use for the right border of the cell * Set the type of border to use for the right border of the cell
* *
* @param border the type of border to use * @param border the type of border to use
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public void setBorderRight(short border) { public void setBorderRight(short border) {
CTBorder ct = getCTBorder(); CTBorder ct = getCTBorder();
@ -787,20 +788,20 @@ public class XSSFCellStyle implements CellStyle {
* Set the type of border to use for the top border of the cell * Set the type of border to use for the top border of the cell
* *
* @param border the type of border to use * @param border the type of border to use
* @see #BORDER_NONE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_NONE
* @see #BORDER_THIN * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THIN
* @see #BORDER_MEDIUM * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM
* @see #BORDER_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASHED
* @see #BORDER_DOTTED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOTTED
* @see #BORDER_THICK * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_THICK
* @see #BORDER_DOUBLE * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DOUBLE
* @see #BORDER_HAIR * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_HAIR
* @see #BORDER_MEDIUM_DASHED * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASHED
* @see #BORDER_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT
* @see #BORDER_MEDIUM_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT
* @see #BORDER_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_DASH_DOT_DOT
* @see #BORDER_MEDIUM_DASH_DOT_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_MEDIUM_DASH_DOT_DOT
* @see #BORDER_SLANTED_DASH_DOT * @see org.apache.poi.ss.usermodel.CellStyle#BORDER_SLANTED_DASH_DOT
*/ */
public void setBorderTop(short border) { public void setBorderTop(short border) {
CTBorder ct = getCTBorder(); CTBorder ct = getCTBorder();
@ -826,7 +827,7 @@ public class XSSFCellStyle implements CellStyle {
/** /**
* Set the color to use for the bottom border * Set the color to use for the bottom border
* @param color the index of the color definition * @param color the index of the color definition
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public void setBottomBorderColor(short color) { public void setBottomBorderColor(short color) {
XSSFColor clr = new XSSFColor(); XSSFColor clr = new XSSFColor();
@ -928,7 +929,7 @@ public class XSSFCellStyle implements CellStyle {
* for the color to be shown in the cell. * for the color to be shown in the cell.
* *
* @param bg - the color to use * @param bg - the color to use
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public void setFillBackgroundColor(short bg) { public void setFillBackgroundColor(short bg) {
XSSFColor clr = new XSSFColor(); XSSFColor clr = new XSSFColor();
@ -965,7 +966,7 @@ public class XSSFCellStyle implements CellStyle {
* <br/> * <br/>
* <i>Note: Ensure Foreground color is set prior to background color.</i> * <i>Note: Ensure Foreground color is set prior to background color.</i>
* @param fg the color to use * @param fg the color to use
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public void setFillForegroundColor(short fg) { public void setFillForegroundColor(short fg) {
XSSFColor clr = new XSSFColor(); XSSFColor clr = new XSSFColor();
@ -1010,26 +1011,26 @@ public class XSSFCellStyle implements CellStyle {
* For solid cell fills (no pattern), foregorund color is used. * For solid cell fills (no pattern), foregorund color is used.
* For cell fills with patterns specified, then the cell fill color is specified by the background color. * For cell fills with patterns specified, then the cell fill color is specified by the background color.
* *
* @see #NO_FILL * @see org.apache.poi.ss.usermodel.CellStyle#NO_FILL
* @see #SOLID_FOREGROUND * @see org.apache.poi.ss.usermodel.CellStyle#SOLID_FOREGROUND
* @see #FINE_DOTS * @see org.apache.poi.ss.usermodel.CellStyle#FINE_DOTS
* @see #ALT_BARS * @see org.apache.poi.ss.usermodel.CellStyle#ALT_BARS
* @see #SPARSE_DOTS * @see org.apache.poi.ss.usermodel.CellStyle#SPARSE_DOTS
* @see #THICK_HORZ_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THICK_HORZ_BANDS
* @see #THICK_VERT_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THICK_VERT_BANDS
* @see #THICK_BACKWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THICK_BACKWARD_DIAG
* @see #THICK_FORWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THICK_FORWARD_DIAG
* @see #BIG_SPOTS * @see org.apache.poi.ss.usermodel.CellStyle#BIG_SPOTS
* @see #BRICKS * @see org.apache.poi.ss.usermodel.CellStyle#BRICKS
* @see #THIN_HORZ_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THIN_HORZ_BANDS
* @see #THIN_VERT_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THIN_VERT_BANDS
* @see #THIN_BACKWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THIN_BACKWARD_DIAG
* @see #THIN_FORWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THIN_FORWARD_DIAG
* @see #SQUARES * @see org.apache.poi.ss.usermodel.CellStyle#SQUARES
* @see #DIAMONDS * @see org.apache.poi.ss.usermodel.CellStyle#DIAMONDS
* @see #setFillBackgroundColor(short) * @see #setFillBackgroundColor(short)
* @see #setFillForegroundColor(short) * @see #setFillForegroundColor(short)
* @param fp fill pattern (set to {@link #SOLID_FOREGROUND} to fill w/foreground color) * @param fp fill pattern (set to {@link org.apache.poi.ss.usermodel.CellStyle#SOLID_FOREGROUND} to fill w/foreground color)
*/ */
public void setFillPattern(short fp) { public void setFillPattern(short fp) {
CTFill ct = getCTFill(); CTFill ct = getCTFill();
@ -1050,7 +1051,7 @@ public class XSSFCellStyle implements CellStyle {
* @param ptrn the fill pattern to use * @param ptrn the fill pattern to use
* @see #setFillBackgroundColor(short) * @see #setFillBackgroundColor(short)
* @see #setFillForegroundColor(short) * @see #setFillForegroundColor(short)
* @see FillPatternType * @see org.apache.poi.ss.usermodel.FillPatternType
*/ */
public void setFillPattern(FillPatternType ptrn) { public void setFillPattern(FillPatternType ptrn) {
setFillPattern((short)ptrn.ordinal()); setFillPattern((short)ptrn.ordinal());
@ -1095,7 +1096,7 @@ public class XSSFCellStyle implements CellStyle {
* Set the color to use for the left border as a indexed color value * Set the color to use for the left border as a indexed color value
* *
* @param color the index of the color definition * @param color the index of the color definition
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public void setLeftBorderColor(short color) { public void setLeftBorderColor(short color) {
XSSFColor clr = new XSSFColor(); XSSFColor clr = new XSSFColor();
@ -1135,7 +1136,7 @@ public class XSSFCellStyle implements CellStyle {
* Set the color to use for the right border * Set the color to use for the right border
* *
* @param color the index of the color definition * @param color the index of the color definition
* @see IndexedColors * @see org.apache.poi.ss.usermodel.IndexedColors
*/ */
public void setRightBorderColor(short color) { public void setRightBorderColor(short color) {
XSSFColor clr = new XSSFColor(); XSSFColor clr = new XSSFColor();
@ -1216,11 +1217,11 @@ public class XSSFCellStyle implements CellStyle {
* Set the type of vertical alignment for the cell * Set the type of vertical alignment for the cell
* *
* @param align - align the type of alignment * @param align - align the type of alignment
* @see #VERTICAL_TOP * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_TOP
* @see #VERTICAL_CENTER * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_CENTER
* @see #VERTICAL_BOTTOM * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_BOTTOM
* @see #VERTICAL_JUSTIFY * @see org.apache.poi.ss.usermodel.CellStyle#VERTICAL_JUSTIFY
* @see VerticalAlignment * @see org.apache.poi.ss.usermodel.VerticalAlignment
*/ */
public void setVerticalAlignment(short align) { public void setVerticalAlignment(short align) {
getCellAlignment().setVertical(VerticalAlignment.values()[align]); getCellAlignment().setVertical(VerticalAlignment.values()[align]);

View File

@ -38,7 +38,7 @@ public class XSSFFont implements Font {
public static final short DEFAULT_FONT_SIZE = 11; public static final short DEFAULT_FONT_SIZE = 11;
/** /**
* Default font color is black * Default font color is black
* @see IndexedColors.BLACK * @see org.apache.poi.ss.usermodel.IndexedColors#BLACK
*/ */
public static final short DEFAULT_FONT_COLOR = IndexedColors.BLACK.getIndex(); public static final short DEFAULT_FONT_COLOR = IndexedColors.BLACK.getIndex();

View File

@ -1,246 +1,244 @@
/* ==================================================================== /* ====================================================================
Licensed to the Apache Software Foundation (ASF) under one or more Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership. this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0 The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with (the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0 http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS, distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
==================================================================== */ ==================================================================== */
package org.apache.poi.xssf.usermodel; package org.apache.poi.xssf.usermodel;
import java.util.Iterator; import java.util.Iterator;
import org.apache.poi.hssf.record.formula.eval.BoolEval; import org.apache.poi.hssf.record.formula.eval.BoolEval;
import org.apache.poi.hssf.record.formula.eval.ErrorEval; import org.apache.poi.hssf.record.formula.eval.ErrorEval;
import org.apache.poi.hssf.record.formula.eval.NumberEval; import org.apache.poi.hssf.record.formula.eval.NumberEval;
import org.apache.poi.hssf.record.formula.eval.StringEval; import org.apache.poi.hssf.record.formula.eval.StringEval;
import org.apache.poi.hssf.record.formula.eval.ValueEval; import org.apache.poi.hssf.record.formula.eval.ValueEval;
import org.apache.poi.hssf.usermodel.HSSFCell; import org.apache.poi.ss.formula.WorkbookEvaluator;
import org.apache.poi.ss.formula.WorkbookEvaluator; import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.Cell; import org.apache.poi.ss.usermodel.CellValue;
import org.apache.poi.ss.usermodel.CellValue; import org.apache.poi.ss.usermodel.FormulaEvaluator;
import org.apache.poi.ss.usermodel.FormulaEvaluator; import org.apache.poi.ss.usermodel.Row;
import org.apache.poi.ss.usermodel.Row; import org.apache.poi.ss.usermodel.Sheet;
import org.apache.poi.ss.usermodel.Sheet;
/**
/** * Evaluates formula cells.<p/>
* Evaluates formula cells.<p/> *
* * For performance reasons, this class keeps a cache of all previously calculated intermediate
* For performance reasons, this class keeps a cache of all previously calculated intermediate * cell values. Be sure to call {@link #clearAllCachedResultValues()} if any workbook cells are changed between
* cell values. Be sure to call {@link #clearCache()} if any workbook cells are changed between * calls to evaluate~ methods on this class.
* calls to evaluate~ methods on this class. *
* * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
* @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; * @author Josh Micich
* @author Josh Micich */
*/ public class XSSFFormulaEvaluator implements FormulaEvaluator {
public class XSSFFormulaEvaluator implements FormulaEvaluator {
private WorkbookEvaluator _bookEvaluator;
private WorkbookEvaluator _bookEvaluator;
public XSSFFormulaEvaluator(XSSFWorkbook workbook) {
public XSSFFormulaEvaluator(XSSFWorkbook workbook) { _bookEvaluator = new WorkbookEvaluator(XSSFEvaluationWorkbook.create(workbook));
_bookEvaluator = new WorkbookEvaluator(XSSFEvaluationWorkbook.create(workbook)); }
}
/**
/** * Should be called whenever there are major changes (e.g. moving sheets) to input cells
* Should be called whenever there are major changes (e.g. moving sheets) to input cells * in the evaluated workbook.
* in the evaluated workbook. * Failure to call this method after changing cell values will cause incorrect behaviour
* Failure to call this method after changing cell values will cause incorrect behaviour * of the evaluate~ methods of this class
* of the evaluate~ methods of this class */
*/ public void clearAllCachedResultValues() {
public void clearAllCachedResultValues() { _bookEvaluator.clearAllCachedResultValues();
_bookEvaluator.clearAllCachedResultValues(); }
} public void notifySetFormula(Cell cell) {
public void notifySetFormula(Cell cell) { _bookEvaluator.notifyUpdateCell(new XSSFEvaluationCell((XSSFCell)cell));
_bookEvaluator.notifyUpdateCell(new XSSFEvaluationCell((XSSFCell)cell)); }
} public void notifyDeleteCell(Cell cell) {
public void notifyDeleteCell(Cell cell) { _bookEvaluator.notifyDeleteCell(new XSSFEvaluationCell((XSSFCell)cell));
_bookEvaluator.notifyDeleteCell(new XSSFEvaluationCell((XSSFCell)cell)); }
}
/**
/** * If cell contains a formula, the formula is evaluated and returned,
* If cell contains a formula, the formula is evaluated and returned, * else the CellValue simply copies the appropriate cell value from
* else the CellValue simply copies the appropriate cell value from * the cell and also its cell type. This method should be preferred over
* the cell and also its cell type. This method should be preferred over * evaluateInCell() when the call should not modify the contents of the
* evaluateInCell() when the call should not modify the contents of the * original cell.
* original cell. * @param cell
* @param cell */
*/ public CellValue evaluate(Cell cell) {
public CellValue evaluate(Cell cell) { if (cell == null) {
if (cell == null) { return null;
return null; }
}
switch (cell.getCellType()) {
switch (cell.getCellType()) { case XSSFCell.CELL_TYPE_BOOLEAN:
case XSSFCell.CELL_TYPE_BOOLEAN: return CellValue.valueOf(cell.getBooleanCellValue());
return CellValue.valueOf(cell.getBooleanCellValue()); case XSSFCell.CELL_TYPE_ERROR:
case XSSFCell.CELL_TYPE_ERROR: return CellValue.getError(cell.getErrorCellValue());
return CellValue.getError(cell.getErrorCellValue()); case XSSFCell.CELL_TYPE_FORMULA:
case XSSFCell.CELL_TYPE_FORMULA: return evaluateFormulaCellValue(cell);
return evaluateFormulaCellValue(cell); case XSSFCell.CELL_TYPE_NUMERIC:
case XSSFCell.CELL_TYPE_NUMERIC: return new CellValue(cell.getNumericCellValue());
return new CellValue(cell.getNumericCellValue()); case XSSFCell.CELL_TYPE_STRING:
case XSSFCell.CELL_TYPE_STRING: return new CellValue(cell.getRichStringCellValue().getString());
return new CellValue(cell.getRichStringCellValue().getString()); }
} throw new IllegalStateException("Bad cell type (" + cell.getCellType() + ")");
throw new IllegalStateException("Bad cell type (" + cell.getCellType() + ")"); }
}
/**
/** * If cell contains formula, it evaluates the formula,
* If cell contains formula, it evaluates the formula, * and saves the result of the formula. The cell
* and saves the result of the formula. The cell * remains as a formula cell.
* remains as a formula cell. * Else if cell does not contain formula, this method leaves
* Else if cell does not contain formula, this method leaves * the cell unchanged.
* the cell unchanged. * Note that the type of the formula result is returned,
* Note that the type of the formula result is returned, * so you know what kind of value is also stored with
* so you know what kind of value is also stored with * the formula.
* the formula. * <pre>
* <pre> * int evaluatedCellType = evaluator.evaluateFormulaCell(cell);
* int evaluatedCellType = evaluator.evaluateFormulaCell(cell); * </pre>
* </pre> * Be aware that your cell will hold both the formula,
* Be aware that your cell will hold both the formula, * and the result. If you want the cell replaced with
* and the result. If you want the cell replaced with * the result of the formula, use {@link #evaluate(org.apache.poi.ss.usermodel.Cell)} }
* the result of the formula, use {@link #evaluateInCell(HSSFCell)} * @param cell The cell to evaluate
* @param cell The cell to evaluate * @return The type of the formula result (the cell's type remains as HSSFCell.CELL_TYPE_FORMULA however)
* @return The type of the formula result (the cell's type remains as HSSFCell.CELL_TYPE_FORMULA however) */
*/ public int evaluateFormulaCell(Cell cell) {
public int evaluateFormulaCell(Cell cell) { if (cell == null || cell.getCellType() != XSSFCell.CELL_TYPE_FORMULA) {
if (cell == null || cell.getCellType() != XSSFCell.CELL_TYPE_FORMULA) { return -1;
return -1; }
} CellValue cv = evaluateFormulaCellValue(cell);
CellValue cv = evaluateFormulaCellValue(cell); // cell remains a formula cell, but the cached value is changed
// cell remains a formula cell, but the cached value is changed setCellValue(cell, cv);
setCellValue(cell, cv); return cv.getCellType();
return cv.getCellType(); }
}
/**
/** * If cell contains formula, it evaluates the formula, and
* If cell contains formula, it evaluates the formula, and * puts the formula result back into the cell, in place
* puts the formula result back into the cell, in place * of the old formula.
* of the old formula. * Else if cell does not contain formula, this method leaves
* Else if cell does not contain formula, this method leaves * the cell unchanged.
* the cell unchanged. * Note that the same instance of HSSFCell is returned to
* Note that the same instance of HSSFCell is returned to * allow chained calls like:
* allow chained calls like: * <pre>
* <pre> * int evaluatedCellType = evaluator.evaluateInCell(cell).getCellType();
* int evaluatedCellType = evaluator.evaluateInCell(cell).getCellType(); * </pre>
* </pre> * Be aware that your cell value will be changed to hold the
* Be aware that your cell value will be changed to hold the * result of the formula. If you simply want the formula
* result of the formula. If you simply want the formula * value computed for you, use {@link #evaluateFormulaCell(org.apache.poi.ss.usermodel.Cell)} }
* value computed for you, use {@link #evaluateFormulaCell(HSSFCell)} * @param cell
* @param cell */
*/ public XSSFCell evaluateInCell(Cell cell) {
public XSSFCell evaluateInCell(Cell cell) { if (cell == null) {
if (cell == null) { return null;
return null; }
} XSSFCell result = (XSSFCell) cell;
XSSFCell result = (XSSFCell) cell; if (cell.getCellType() == XSSFCell.CELL_TYPE_FORMULA) {
if (cell.getCellType() == XSSFCell.CELL_TYPE_FORMULA) { CellValue cv = evaluateFormulaCellValue(cell);
CellValue cv = evaluateFormulaCellValue(cell); setCellType(cell, cv); // cell will no longer be a formula cell
setCellType(cell, cv); // cell will no longer be a formula cell setCellValue(cell, cv);
setCellValue(cell, cv); }
} return result;
return result; }
} private static void setCellType(Cell cell, CellValue cv) {
private static void setCellType(Cell cell, CellValue cv) { int cellType = cv.getCellType();
int cellType = cv.getCellType(); switch (cellType) {
switch (cellType) { case XSSFCell.CELL_TYPE_BOOLEAN:
case XSSFCell.CELL_TYPE_BOOLEAN: case XSSFCell.CELL_TYPE_ERROR:
case XSSFCell.CELL_TYPE_ERROR: case XSSFCell.CELL_TYPE_NUMERIC:
case XSSFCell.CELL_TYPE_NUMERIC: case XSSFCell.CELL_TYPE_STRING:
case XSSFCell.CELL_TYPE_STRING: cell.setCellType(cellType);
cell.setCellType(cellType); return;
return; case XSSFCell.CELL_TYPE_BLANK:
case XSSFCell.CELL_TYPE_BLANK: // never happens - blanks eventually get translated to zero
// never happens - blanks eventually get translated to zero case XSSFCell.CELL_TYPE_FORMULA:
case XSSFCell.CELL_TYPE_FORMULA: // this will never happen, we have already evaluated the formula
// this will never happen, we have already evaluated the formula }
} throw new IllegalStateException("Unexpected cell value type (" + cellType + ")");
throw new IllegalStateException("Unexpected cell value type (" + cellType + ")"); }
}
private static void setCellValue(Cell cell, CellValue cv) {
private static void setCellValue(Cell cell, CellValue cv) { int cellType = cv.getCellType();
int cellType = cv.getCellType(); switch (cellType) {
switch (cellType) { case XSSFCell.CELL_TYPE_BOOLEAN:
case XSSFCell.CELL_TYPE_BOOLEAN: cell.setCellValue(cv.getBooleanValue());
cell.setCellValue(cv.getBooleanValue()); break;
break; case XSSFCell.CELL_TYPE_ERROR:
case XSSFCell.CELL_TYPE_ERROR: cell.setCellErrorValue(cv.getErrorValue());
cell.setCellErrorValue(cv.getErrorValue()); break;
break; case XSSFCell.CELL_TYPE_NUMERIC:
case XSSFCell.CELL_TYPE_NUMERIC: cell.setCellValue(cv.getNumberValue());
cell.setCellValue(cv.getNumberValue()); break;
break; case XSSFCell.CELL_TYPE_STRING:
case XSSFCell.CELL_TYPE_STRING: cell.setCellValue(new XSSFRichTextString(cv.getStringValue()));
cell.setCellValue(new XSSFRichTextString(cv.getStringValue())); break;
break; case XSSFCell.CELL_TYPE_BLANK:
case XSSFCell.CELL_TYPE_BLANK: // never happens - blanks eventually get translated to zero
// never happens - blanks eventually get translated to zero case XSSFCell.CELL_TYPE_FORMULA:
case XSSFCell.CELL_TYPE_FORMULA: // this will never happen, we have already evaluated the formula
// this will never happen, we have already evaluated the formula default:
default: throw new IllegalStateException("Unexpected cell value type (" + cellType + ")");
throw new IllegalStateException("Unexpected cell value type (" + cellType + ")"); }
} }
}
/**
/** * Loops over all cells in all sheets of the supplied
* Loops over all cells in all sheets of the supplied * workbook.
* workbook. * For cells that contain formulas, their formulas are
* For cells that contain formulas, their formulas are * evaluated, and the results are saved. These cells
* evaluated, and the results are saved. These cells * remain as formula cells.
* remain as formula cells. * For cells that do not contain formulas, no changes
* For cells that do not contain formulas, no changes * are made.
* are made. * This is a helpful wrapper around looping over all
* This is a helpful wrapper around looping over all * cells, and calling evaluateFormulaCell on each one.
* cells, and calling evaluateFormulaCell on each one. */
*/ public static void evaluateAllFormulaCells(XSSFWorkbook wb) {
public static void evaluateAllFormulaCells(XSSFWorkbook wb) { XSSFFormulaEvaluator evaluator = new XSSFFormulaEvaluator(wb);
XSSFFormulaEvaluator evaluator = new XSSFFormulaEvaluator(wb); for(int i=0; i<wb.getNumberOfSheets(); i++) {
for(int i=0; i<wb.getNumberOfSheets(); i++) { Sheet sheet = wb.getSheetAt(i);
Sheet sheet = wb.getSheetAt(i);
for (Iterator<Row> rit = sheet.rowIterator(); rit.hasNext();) {
for (Iterator<Row> rit = sheet.rowIterator(); rit.hasNext();) { Row r = rit.next();
Row r = rit.next();
for (Iterator cit = r.cellIterator(); cit.hasNext();) {
for (Iterator cit = r.cellIterator(); cit.hasNext();) { XSSFCell c = (XSSFCell) cit.next();
XSSFCell c = (XSSFCell) cit.next(); if (c.getCellType() == XSSFCell.CELL_TYPE_FORMULA)
if (c.getCellType() == XSSFCell.CELL_TYPE_FORMULA) evaluator.evaluateFormulaCell(c);
evaluator.evaluateFormulaCell(c); }
} }
} }
} }
}
/**
/** * Returns a CellValue wrapper around the supplied ValueEval instance.
* Returns a CellValue wrapper around the supplied ValueEval instance. */
* @param eval private CellValue evaluateFormulaCellValue(Cell cell) {
*/ ValueEval eval = _bookEvaluator.evaluate(new XSSFEvaluationCell((XSSFCell) cell));
private CellValue evaluateFormulaCellValue(Cell cell) { if (eval instanceof NumberEval) {
ValueEval eval = _bookEvaluator.evaluate(new XSSFEvaluationCell((XSSFCell) cell)); NumberEval ne = (NumberEval) eval;
if (eval instanceof NumberEval) { return new CellValue(ne.getNumberValue());
NumberEval ne = (NumberEval) eval; }
return new CellValue(ne.getNumberValue()); if (eval instanceof BoolEval) {
} BoolEval be = (BoolEval) eval;
if (eval instanceof BoolEval) { return CellValue.valueOf(be.getBooleanValue());
BoolEval be = (BoolEval) eval; }
return CellValue.valueOf(be.getBooleanValue()); if (eval instanceof StringEval) {
} StringEval ne = (StringEval) eval;
if (eval instanceof StringEval) { return new CellValue(ne.getStringValue());
StringEval ne = (StringEval) eval; }
return new CellValue(ne.getStringValue()); if (eval instanceof ErrorEval) {
} return CellValue.getError(((ErrorEval)eval).getErrorCode());
if (eval instanceof ErrorEval) { }
return CellValue.getError(((ErrorEval)eval).getErrorCode()); throw new RuntimeException("Unexpected eval class (" + eval.getClass().getName() + ")");
} }
throw new RuntimeException("Unexpected eval class (" + eval.getClass().getName() + ")"); }
}
}

View File

@ -223,7 +223,8 @@ public class XSSFPicture extends XSSFShape {
* Return the dimension of this image * Return the dimension of this image
* *
* @param part the package part holding raw picture data * @param part the package part holding raw picture data
* @param type type of the picture: {@link Workbook#PICTURE_TYPE_JPEG, Workbook#PICTURE_TYPE_PNG or Workbook#PICTURE_TYPE_DIB) * @param type type of the picture: {@link Workbook#PICTURE_TYPE_JPEG},
* {@link Workbook#PICTURE_TYPE_PNG} or {@link Workbook#PICTURE_TYPE_DIB}
* *
* @return image dimension in pixels * @return image dimension in pixels
*/ */

View File

@ -101,12 +101,12 @@ public class XSSFPictureData extends POIXMLDocumentPart implements PictureData {
* Return an integer constant that specifies type of this picture * Return an integer constant that specifies type of this picture
* *
* @return an integer constant that specifies type of this picture * @return an integer constant that specifies type of this picture
* @see Workbook#PICTURE_TYPE_EMF * @see org.apache.poi.ss.usermodel.Workbook#PICTURE_TYPE_EMF
* @see Workbook#PICTURE_TYPE_WMF * @see org.apache.poi.ss.usermodel.Workbook#PICTURE_TYPE_WMF
* @see Workbook#PICTURE_TYPE_PICT * @see org.apache.poi.ss.usermodel.Workbook#PICTURE_TYPE_PICT
* @see Workbook#PICTURE_TYPE_JPEG * @see org.apache.poi.ss.usermodel.Workbook#PICTURE_TYPE_JPEG
* @see Workbook#PICTURE_TYPE_PNG * @see org.apache.poi.ss.usermodel.Workbook#PICTURE_TYPE_PNG
* @see Workbook#PICTURE_TYPE_DIB * @see org.apache.poi.ss.usermodel.Workbook#PICTURE_TYPE_DIB
*/ */
public int getPictureType(){ public int getPictureType(){
String contentType = getPackagePart().getContentType(); String contentType = getPackagePart().getContentType();

View File

@ -163,7 +163,7 @@ public class XSSFRow implements Row, Comparable<XSSFRow> {
/** /**
* Returns the cell at the given (0 based) index, * Returns the cell at the given (0 based) index,
* with the {@link MissingCellPolicy} from the parent Workbook. * with the {@link org.apache.poi.ss.usermodel.Row.MissingCellPolicy} from the parent Workbook.
* *
* @return the cell at the given (0 based) index * @return the cell at the given (0 based) index
*/ */
@ -172,7 +172,7 @@ public class XSSFRow implements Row, Comparable<XSSFRow> {
} }
/** /**
* Returns the cell at the given (0 based) index, with the specified {@link MissingCellPolicy} * Returns the cell at the given (0 based) index, with the specified {@link org.apache.poi.ss.usermodel.Row.MissingCellPolicy}
* *
* @return the cell at the given (0 based) index * @return the cell at the given (0 based) index
* @throws IllegalArgumentException if cellnum < 0 or the specified MissingCellPolicy is invalid * @throws IllegalArgumentException if cellnum < 0 or the specified MissingCellPolicy is invalid

View File

@ -254,12 +254,12 @@ public class XSSFWorkbook extends POIXMLDocument implements Workbook, Iterable<X
* @param format The format of the picture. * @param format The format of the picture.
* *
* @return the index to this picture (0 based), the added picture can be obtained from {@link #getAllPictures()} . * @return the index to this picture (0 based), the added picture can be obtained from {@link #getAllPictures()} .
* @see #PICTURE_TYPE_EMF * @see Workbook#PICTURE_TYPE_EMF
* @see #PICTURE_TYPE_WMF * @see Workbook#PICTURE_TYPE_WMF
* @see #PICTURE_TYPE_PICT * @see Workbook#PICTURE_TYPE_PICT
* @see #PICTURE_TYPE_JPEG * @see Workbook#PICTURE_TYPE_JPEG
* @see #PICTURE_TYPE_PNG * @see Workbook#PICTURE_TYPE_PNG
* @see #PICTURE_TYPE_DIB * @see Workbook#PICTURE_TYPE_DIB
* @see #getAllPictures() * @see #getAllPictures()
*/ */
public int addPicture(byte[] pictureData, int format) { public int addPicture(byte[] pictureData, int format) {
@ -283,12 +283,12 @@ public class XSSFWorkbook extends POIXMLDocument implements Workbook, Iterable<X
* @param format The format of the picture. * @param format The format of the picture.
* *
* @return the index to this picture (0 based), the added picture can be obtained from {@link #getAllPictures()} . * @return the index to this picture (0 based), the added picture can be obtained from {@link #getAllPictures()} .
* @see #PICTURE_TYPE_EMF * @see Workbook#PICTURE_TYPE_EMF
* @see #PICTURE_TYPE_WMF * @see Workbook#PICTURE_TYPE_WMF
* @see #PICTURE_TYPE_PICT * @see Workbook#PICTURE_TYPE_PICT
* @see #PICTURE_TYPE_JPEG * @see Workbook#PICTURE_TYPE_JPEG
* @see #PICTURE_TYPE_PNG * @see Workbook#PICTURE_TYPE_PNG
* @see #PICTURE_TYPE_DIB * @see Workbook#PICTURE_TYPE_DIB
* @see #getAllPictures() * @see #getAllPictures()
*/ */
public int addPicture(InputStream is, int format) throws IOException { public int addPicture(InputStream is, int format) throws IOException {

View File

@ -111,10 +111,6 @@ public abstract class XSSFHeaderFooter implements HeaderFooter {
return this.headerFooter; return this.headerFooter;
} }
/**
*
* @return
*/
public String getValue() { public String getValue() {
String value = getText(); String value = getText();
if(value == null) if(value == null)

View File

@ -78,7 +78,7 @@ public class ActiveXShape extends Picture {
/** /**
* Assign a control to this shape * Assign a control to this shape
* *
* @see {@link org.apache.poi.hslf.usermodel.SlideShow#addMovie(String, int)} * @see org.apache.poi.hslf.usermodel.SlideShow#addMovie(String, int)
* @param idx the index of the movie * @param idx the index of the movie
*/ */
public void setActiveXIndex(int idx){ public void setActiveXIndex(int idx){

View File

@ -95,7 +95,7 @@ public class MovieShape extends Picture {
/** /**
* Assign a movie to this shape * Assign a movie to this shape
* *
* @see {@link org.apache.poi.hslf.usermodel.SlideShow#addMovie(String, int)} * @see org.apache.poi.hslf.usermodel.SlideShow#addMovie(String, int)
* @param idx the index of the movie * @param idx the index of the movie
*/ */
public void setMovieIndex(int idx){ public void setMovieIndex(int idx){

View File

@ -104,7 +104,6 @@ public class OLEShape extends Picture {
* 5. CString (4026), Instance ClipboardName (3) that appears in the paste special dialog. * 5. CString (4026), Instance ClipboardName (3) that appears in the paste special dialog.
* 6. MetaFile( 4033), optional * 6. MetaFile( 4033), optional
* </p> * </p>
* @return
*/ */
public ExEmbed getExEmbed(){ public ExEmbed getExEmbed(){
if(_exEmbed == null){ if(_exEmbed == null){

View File

@ -203,14 +203,14 @@ public class AnimationInfoAtom extends RecordAtom
/** /**
* A signed integer that specifies the delay time, in milliseconds, before the animation starts to play. * A signed integer that specifies the delay time, in milliseconds, before the animation starts to play.
* If {@link Automatic} is 0x1, this value MUST be greater than or equal to 0; otherwise, this field MUST be ignored. * If {@link #Automatic} is 0x1, this value MUST be greater than or equal to 0; otherwise, this field MUST be ignored.
*/ */
public int getDelayTime(){ public int getDelayTime(){
return LittleEndian.getInt(_recdata, 12); return LittleEndian.getInt(_recdata, 12);
} }
/** /**
* A signed integer that specifies the delay time, in milliseconds, before the animation starts to play. * A signed integer that specifies the delay time, in milliseconds, before the animation starts to play.
* If {@link Automatic} is 0x1, this value MUST be greater than or equal to 0; otherwise, this field MUST be ignored. * If {@link #Automatic} is 0x1, this value MUST be greater than or equal to 0; otherwise, this field MUST be ignored.
*/ */
public void setDelayTime(int id){ public void setDelayTime(int id){
LittleEndian.putInt(_recdata, 12, id); LittleEndian.putInt(_recdata, 12, id);

View File

@ -34,13 +34,15 @@ public class HeadersFootersAtom extends RecordAtom {
/** /**
* A bit that specifies whether the date is displayed in the footer. * A bit that specifies whether the date is displayed in the footer.
* @see {@link #getMask()}, {@link #setMask(int)}}, * @see #getMask()
* @see #setMask(int)
*/ */
public static final int fHasDate = 1; public static final int fHasDate = 1;
/** /**
* A bit that specifies whether the current datetime is used for displaying the datetime. * A bit that specifies whether the current datetime is used for displaying the datetime.
* @see {@link #getMask()}, {@link #setMask(int)}}, * @see #getMask()
* @see #setMask(int)
*/ */
public static final int fHasTodayDate = 2; public static final int fHasTodayDate = 2;
@ -48,28 +50,32 @@ public class HeadersFootersAtom extends RecordAtom {
* A bit that specifies whether the date specified in UserDateAtom record * A bit that specifies whether the date specified in UserDateAtom record
* is used for displaying the datetime. * is used for displaying the datetime.
* *
* @see {@link #getMask()}, {@link #setMask(int)}}, * @see #getMask()
* @see #setMask(int)
*/ */
public static final int fHasUserDate = 4; public static final int fHasUserDate = 4;
/** /**
* A bit that specifies whether the slide number is displayed in the footer. * A bit that specifies whether the slide number is displayed in the footer.
* *
* @see {@link #getMask()}, {@link #setMask(int)}}, * @see #getMask()
* @see #setMask(int)
*/ */
public static final int fHasSlideNumber = 8; public static final int fHasSlideNumber = 8;
/** /**
* bit that specifies whether the header text is displayed. * bit that specifies whether the header text is displayed.
* *
* @see {@link #getMask()}, {@link #setMask(int)}}, * @see #getMask()
* @see #setMask(int)
*/ */
public static final int fHasHeader = 16; public static final int fHasHeader = 16;
/** /**
* bit that specifies whether the footer text is displayed. * bit that specifies whether the footer text is displayed.
* *
* @see {@link #getMask()}, {@link #setMask(int)}}, * @see #getMask()
* @see #setMask(int)
*/ */
public static final int fHasFooter = 32; public static final int fHasFooter = 32;

View File

@ -75,7 +75,6 @@ public class MAPIMessage {
/** /**
* Gets a string value based on the passed chunk. * Gets a string value based on the passed chunk.
* @param chunk * @param chunk
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getStringFromChunk(StringChunk chunk) throws ChunkNotFoundException { public String getStringFromChunk(StringChunk chunk) throws ChunkNotFoundException {
@ -97,7 +96,6 @@ public class MAPIMessage {
/** /**
* Gets the subject line of the Outlook Message * Gets the subject line of the Outlook Message
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getSubject() throws ChunkNotFoundException { public String getSubject() throws ChunkNotFoundException {
@ -108,7 +106,6 @@ public class MAPIMessage {
/** /**
* Gets the display value of the "TO" line of the outlook message * Gets the display value of the "TO" line of the outlook message
* This is not the actual list of addresses/values that will be sent to if you click Reply in the email. * This is not the actual list of addresses/values that will be sent to if you click Reply in the email.
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getDisplayTo() throws ChunkNotFoundException { public String getDisplayTo() throws ChunkNotFoundException {
@ -118,7 +115,6 @@ public class MAPIMessage {
/** /**
* Gets the display value of the "FROM" line of the outlook message * Gets the display value of the "FROM" line of the outlook message
* This is not the actual address that was sent from but the formated display of the user name. * This is not the actual address that was sent from but the formated display of the user name.
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getDisplayFrom() throws ChunkNotFoundException { public String getDisplayFrom() throws ChunkNotFoundException {
@ -128,7 +124,6 @@ public class MAPIMessage {
/** /**
* Gets the display value of the "TO" line of the outlook message * Gets the display value of the "TO" line of the outlook message
* This is not the actual list of addresses/values that will be sent to if you click Reply in the email. * This is not the actual list of addresses/values that will be sent to if you click Reply in the email.
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getDisplayCC() throws ChunkNotFoundException { public String getDisplayCC() throws ChunkNotFoundException {
@ -138,7 +133,6 @@ public class MAPIMessage {
/** /**
* Gets the display value of the "TO" line of the outlook message * Gets the display value of the "TO" line of the outlook message
* This is not the actual list of addresses/values that will be sent to if you click Reply in the email. * This is not the actual list of addresses/values that will be sent to if you click Reply in the email.
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getDisplayBCC() throws ChunkNotFoundException { public String getDisplayBCC() throws ChunkNotFoundException {
@ -149,7 +143,6 @@ public class MAPIMessage {
/** /**
* Gets the conversation topic of the parsed Outlook Message. * Gets the conversation topic of the parsed Outlook Message.
* This is the part of the subject line that is after the RE: and FWD: * This is the part of the subject line that is after the RE: and FWD:
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getConversationTopic() throws ChunkNotFoundException { public String getConversationTopic() throws ChunkNotFoundException {
@ -161,7 +154,6 @@ public class MAPIMessage {
* (Yes, you can use this to determine if a message is a calendar item, note, or actual outlook Message) * (Yes, you can use this to determine if a message is a calendar item, note, or actual outlook Message)
* For emails the class will be IPM.Note * For emails the class will be IPM.Note
* *
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public String getMessageClass() throws ChunkNotFoundException { public String getMessageClass() throws ChunkNotFoundException {

View File

@ -26,7 +26,6 @@ abstract public class Chunk {
/** /**
* Gets the id of this chunk * Gets the id of this chunk
* @return
*/ */
public int getChunkId() { public int getChunkId() {
return this.chunkId; return this.chunkId;
@ -34,7 +33,6 @@ abstract public class Chunk {
/** /**
* Gets the numeric type of this chunk. * Gets the numeric type of this chunk.
* @return
*/ */
public int getType() { public int getType() {
return this.type; return this.type;
@ -42,7 +40,6 @@ abstract public class Chunk {
/** /**
* Creates a string to use to identify this chunk in the POI file system object. * Creates a string to use to identify this chunk in the POI file system object.
* @return
*/ */
public String getEntryName() { public String getEntryName() {
String type = Integer.toHexString(this.type); String type = Integer.toHexString(this.type);
@ -56,7 +53,6 @@ abstract public class Chunk {
/** /**
* Gets a reference to a ByteArrayOutputStream that contains the value of this chunk. * Gets a reference to a ByteArrayOutputStream that contains the value of this chunk.
* @return
*/ */
public abstract ByteArrayOutputStream getValueByteArray(); public abstract ByteArrayOutputStream getValueByteArray();

View File

@ -66,7 +66,6 @@ public class POIFSChunkParser {
/** /**
* Get a reference to the FileSystem object that this object is currently using. * Get a reference to the FileSystem object that this object is currently using.
* @return
*/ */
public POIFSFileSystem getFileSystem() { public POIFSFileSystem getFileSystem() {
return this.fs; return this.fs;
@ -117,7 +116,6 @@ public class POIFSChunkParser {
/** /**
* Pull the chunk data that's stored in this object's hashmap out and return it as a HashMap. * Pull the chunk data that's stored in this object's hashmap out and return it as a HashMap.
* @param entryName * @param entryName
* @return
*/ */
public Object getChunk(HashMap dirMap, String entryName) { public Object getChunk(HashMap dirMap, String entryName) {
if(dirMap == null) return null; if(dirMap == null) return null;
@ -143,8 +141,8 @@ public class POIFSChunkParser {
/** /**
* Pulls a ByteArrayOutputStream from this objects HashMap, this can be used to read a byte array of the contents of the given chunk. * Pulls a ByteArrayOutputStream from this objects HashMap, this can be used to read a byte array of the contents of the given chunk.
* @param directoryMap, chunk * @param dirNode
* @return * @param chunk
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public Chunk getDocumentNode(HashMap dirNode, Chunk chunk) throws ChunkNotFoundException { public Chunk getDocumentNode(HashMap dirNode, Chunk chunk) throws ChunkNotFoundException {
@ -161,7 +159,6 @@ public class POIFSChunkParser {
/** /**
* Pulls a Chunk out of this objects root Node tree. * Pulls a Chunk out of this objects root Node tree.
* @param chunk * @param chunk
* @return
* @throws ChunkNotFoundException * @throws ChunkNotFoundException
*/ */
public Chunk getDocumentNode(Chunk chunk) throws ChunkNotFoundException { public Chunk getDocumentNode(Chunk chunk) throws ChunkNotFoundException {

View File

@ -72,7 +72,7 @@ public class PicturesTable
/** /**
* *
* @param document * @param _document
* @param _dataStream * @param _dataStream
*/ */
public PicturesTable(HWPFDocument _document, byte[] _dataStream, byte[] _mainStream, FSPATable fspa, EscherRecordHolder dgg) public PicturesTable(HWPFDocument _document, byte[] _dataStream, byte[] _mainStream, FSPATable fspa, EscherRecordHolder dgg)

View File

@ -105,7 +105,6 @@ public class TextPiece extends PropertyNode implements Comparable
* Works only in characters, not in bytes! * Works only in characters, not in bytes!
* @param start Local start position, in characters * @param start Local start position, in characters
* @param end Local end position, in characters * @param end Local end position, in characters
* @return
*/ */
public String substring(int start, int end) public String substring(int start, int end)
{ {

View File

@ -157,7 +157,7 @@ public class TextPieceTable
* In a very evil fashion, you have to actually * In a very evil fashion, you have to actually
* know this to make sense of character and * know this to make sense of character and
* paragraph properties :( * paragraph properties :(
* @param cp The character offset to check about * @param bytePos The character offset to check about
*/ */
public boolean isUnicodeAtByteOffset(int bytePos) { public boolean isUnicodeAtByteOffset(int bytePos) {
boolean lastWas = false; boolean lastWas = false;

View File

@ -89,7 +89,6 @@ public class HeaderStories {
* Returns the correct, defined header for the given * Returns the correct, defined header for the given
* one based page * one based page
* @param pageNumber The one based page number * @param pageNumber The one based page number
* @return
*/ */
public String getHeader(int pageNumber) { public String getHeader(int pageNumber) {
// First page header is optional, only return // First page header is optional, only return
@ -124,7 +123,6 @@ public class HeaderStories {
* Returns the correct, defined footer for the given * Returns the correct, defined footer for the given
* one based page * one based page
* @param pageNumber The one based page number * @param pageNumber The one based page number
* @return
*/ */
public String getFooter(int pageNumber) { public String getFooter(int pageNumber) {
// First page footer is optional, only return // First page footer is optional, only return

View File

@ -81,7 +81,7 @@ public final class TestHSSFFormulaEvaluator extends TestCase {
} }
/** /**
* {@link HSSFFormulaEvaluator#evaluate(HSSFCell)} should behave the same whether the cell * {@link HSSFFormulaEvaluator#evaluate(org.apache.poi.ss.usermodel.Cell)} should behave the same whether the cell
* is <code>null</code> or blank. * is <code>null</code> or blank.
*/ */
public void testEvaluateBlank() { public void testEvaluateBlank() {

View File

@ -23,7 +23,7 @@ import org.apache.poi.hssf.record.formula.eval.NumberEval;
import org.apache.poi.hssf.record.formula.eval.ValueEval; import org.apache.poi.hssf.record.formula.eval.ValueEval;
/** /**
* Tests {@link CellCacheEntry}. * Tests {@link org.apache.poi.ss.formula.CellCacheEntry}.
* *
* @author Josh Micich * @author Josh Micich
*/ */

View File

@ -47,7 +47,7 @@ import org.apache.poi.ss.formula.PlainCellCache.Loc;
import org.apache.poi.ss.usermodel.CellValue; import org.apache.poi.ss.usermodel.CellValue;
/** /**
* Tests {@link EvaluationCache}. Makes sure that where possible (previously calculated) cached * Tests {@link org.apache.poi.ss.formula.EvaluationCache}. Makes sure that where possible (previously calculated) cached
* values are used. Also checks that changing cell values causes the correct (minimal) set of * values are used. Also checks that changing cell values causes the correct (minimal) set of
* dependent cached values to be cleared. * dependent cached values to be cleared.
* *