aboutsummaryrefslogtreecommitdiffstats
path: root/poi-excelant/src
diff options
context:
space:
mode:
authorAndreas Beeker <kiwiwings@apache.org>2021-05-21 21:22:40 +0000
committerAndreas Beeker <kiwiwings@apache.org>2021-05-21 21:22:40 +0000
commit7eaca60a1a364ce6e232363d27823e971a992705 (patch)
tree718fc0e7ccd8c4ed50c2dcd579c4df10cc8b9581 /poi-excelant/src
parentcecab7f573f0cdf9ea74bedcf9b43dc535976e43 (diff)
downloadpoi-7eaca60a1a364ce6e232363d27823e971a992705.tar.gz
poi-7eaca60a1a364ce6e232363d27823e971a992705.zip
activate javadoc lint and fix errors
add signing and checksum generation add slf4j-bridge for tests add dependencies to ooxml-lite fix complex enum classes add override annotations move gradle logic to root build generate javadoc in its own dist directory, because JPMS complains about duplicate modules otherwise git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1890089 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'poi-excelant/src')
-rw-r--r--poi-excelant/src/main/java/org/apache/poi/ss/excelant/ExcelAntHandlerTask.java4
-rw-r--r--poi-excelant/src/main/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java37
2 files changed, 5 insertions, 36 deletions
diff --git a/poi-excelant/src/main/java/org/apache/poi/ss/excelant/ExcelAntHandlerTask.java b/poi-excelant/src/main/java/org/apache/poi/ss/excelant/ExcelAntHandlerTask.java
index 23c2583da8..b2f9266d76 100644
--- a/poi-excelant/src/main/java/org/apache/poi/ss/excelant/ExcelAntHandlerTask.java
+++ b/poi-excelant/src/main/java/org/apache/poi/ss/excelant/ExcelAntHandlerTask.java
@@ -23,7 +23,7 @@ import org.apache.tools.ant.Project;
import org.apache.tools.ant.Task;
/**
- * This is the class that backs the <handler> tag in the Ant task.
+ * This is the class that backs the {@code <handler>} tag in the Ant task.
* <p>
* Its purpose is to provide a way to manipulate a workbook in the course
* of an ExcelAnt task. The idea being to model a way for test writers to
@@ -36,7 +36,7 @@ import org.apache.tools.ant.Task;
* class you write to manipulate the workbook.
* <p>
* In order to use this tag you must write a class that implements the
- * <code>IExcelAntWorkbookHandler</code> interface. After writing the
+ * {@code IExcelAntWorkbookHandler} interface. After writing the
* class you should package it and it's dependencies into a jar file to
* add as library in your Ant build file.
*/
diff --git a/poi-excelant/src/main/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java b/poi-excelant/src/main/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java
index 69616c5310..0bb0cb2ec2 100644
--- a/poi-excelant/src/main/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java
+++ b/poi-excelant/src/main/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java
@@ -187,8 +187,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Returns the Workbook instance associated with this WorkbookUtil.
- *
- * @return
*/
public Workbook getWorkbook() {
return workbook;
@@ -197,8 +195,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Returns the fileName that was used to initialize this instance. May
* return null if the instance was constructed from a Workbook object.
- *
- * @return
*/
public String getFileName() {
return excelFileName;
@@ -206,8 +202,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Returns the list of sheet names.
- *
- * @return
*/
public List<String> getSheets() {
ArrayList<String> sheets = new ArrayList<>();
@@ -224,9 +218,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* This method uses a String in standard Excel format (SheetName!CellId) to
* locate the cell and set it to the value of the double in value.
- *
- * @param cellName
- * @param value
*/
public void setDoubleValue(String cellName, double value) {
log("starting setCellValue()", Project.MSG_DEBUG);
@@ -240,9 +231,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Utility method for setting the value of a Cell with a String.
- *
- * @param cellName
- * @param value
*/
public void setStringValue(String cellName, String value) {
Cell cell = getCell(cellName);
@@ -251,9 +239,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Utility method for setting the value of a Cell with a Formula.
- *
- * @param cellName
- * @param formula
*/
public void setFormulaValue(String cellName, String formula) {
Cell cell = getCell(cellName);
@@ -262,8 +247,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Utility method for setting the value of a Cell with a Date.
- * @param cellName
- * @param date
*/
public void setDateValue(String cellName, Date date) {
Cell cell = getCell(cellName);
@@ -272,15 +255,11 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Uses a String in standard Excel format (SheetName!CellId) to locate a
* cell and evaluate it.
- *
- * @param cellName
- * @param expectedValue
- * @param precision
*/
public ExcelAntEvaluationResult evaluateCell(String cellName, double expectedValue,
double precision) {
- ExcelAntEvaluationResult evalResults = null;
+ ExcelAntEvaluationResult evalResults;
Cell cell = getCell(cellName);
@@ -304,12 +283,11 @@ public class ExcelAntWorkbookUtil extends Typedef {
"Evaluation passed without error within in range.", delta, cellName);
}
} else {
- String errorMeaning = null;
+ String errorMeaning;
try {
errorMeaning = FormulaError.forInt(resultOfEval.getErrorValue()).getString();
} catch(IllegalArgumentException iae) {
- errorMeaning = "unknown error code: " +
- Byte.toString(resultOfEval.getErrorValue());
+ errorMeaning = "unknown error code: " + resultOfEval.getErrorValue();
}
evalResults = new ExcelAntEvaluationResult(true, false,
@@ -325,9 +303,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Returns a Cell as a String value.
- *
- * @param cellName
- * @return
*/
public String getCellAsString(String cellName) {
Cell cell = getCell(cellName);
@@ -337,9 +312,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
/**
* Returns the value of the Cell as a double.
- *
- * @param cellName
- * @return
*/
public double getCellAsDouble(String cellName) {
Cell cell = getCell(cellName);
@@ -349,9 +321,6 @@ public class ExcelAntWorkbookUtil extends Typedef {
* Returns a cell reference based on a String in standard Excel format
* (SheetName!CellId). This method will create a new cell if the
* requested cell isn't initialized yet.
- *
- * @param cellName
- * @return
*/
private Cell getCell(String cellName) {
CellReference cellRef = new CellReference(cellName);