]> source.dussan.org Git - poi.git/commitdiff
Changed CRLF to LF in function implementations. Removed subclasses of NotImplemented...
authorJosh Micich <josh@apache.org>
Wed, 20 May 2009 00:14:19 +0000 (00:14 +0000)
committerJosh Micich <josh@apache.org>
Wed, 20 May 2009 00:14:19 +0000 (00:14 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@776505 13f79535-47bb-0310-9956-ffa450edef68

236 files changed:
src/java/org/apache/poi/hssf/record/formula/eval/FunctionEval.java
src/java/org/apache/poi/hssf/record/formula/functions/Absref.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Activecell.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Address.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/AggregateFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/And.java
src/java/org/apache/poi/hssf/record/formula/functions/Areas.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Argument.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Asc.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Averagea.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Betadist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Betainv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Binomdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/BooleanFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/CalendarFieldFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/Call.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Caller.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Cell.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Char.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Chidist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Chiinv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Chitest.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Choose.java
src/java/org/apache/poi/hssf/record/formula/functions/Clean.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Code.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Column.java
src/java/org/apache/poi/hssf/record/formula/functions/Columns.java
src/java/org/apache/poi/hssf/record/formula/functions/Confidence.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Correl.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Count.java
src/java/org/apache/poi/hssf/record/formula/functions/CountUtils.java
src/java/org/apache/poi/hssf/record/formula/functions/Counta.java
src/java/org/apache/poi/hssf/record/formula/functions/Countblank.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Countif.java
src/java/org/apache/poi/hssf/record/formula/functions/Covar.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Critbinom.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Customrepeat.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/DateFunc.java
src/java/org/apache/poi/hssf/record/formula/functions/Datedif.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Datestring.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Datevalue.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Daverage.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Days360.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Db.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dbcs.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dcount.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dcounta.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Ddb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Deref.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dget.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dmax.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dmin.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dproduct.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dstdev.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dstdevp.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dsum.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dvar.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Dvarp.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Echo.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Error.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Errortype.java
src/java/org/apache/poi/hssf/record/formula/functions/Evaluate.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Even.java
src/java/org/apache/poi/hssf/record/formula/functions/Exec.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Expondist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/False.java
src/java/org/apache/poi/hssf/record/formula/functions/Fdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Files.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/FinanceFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/FinanceLib.java
src/java/org/apache/poi/hssf/record/formula/functions/Find.java
src/java/org/apache/poi/hssf/record/formula/functions/Findb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Finv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Fisher.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Fisherinv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Fixed.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Forecast.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Formulaconvert.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Fpos.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/FreeRefFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/Frequency.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Ftest.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Function.java
src/java/org/apache/poi/hssf/record/formula/functions/Gammadist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Gammainv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Gammaln.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Geomean.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Goto.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Group.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Growth.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Halt.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Harmean.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Help.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Hlookup.java
src/java/org/apache/poi/hssf/record/formula/functions/Hour.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Hyperlink.java
src/java/org/apache/poi/hssf/record/formula/functions/Hypgeomdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/If.java
src/java/org/apache/poi/hssf/record/formula/functions/Index.java
src/java/org/apache/poi/hssf/record/formula/functions/Indirect.java
src/java/org/apache/poi/hssf/record/formula/functions/Info.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Initiate.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Input.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Intercept.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Ipmt.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Irr.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/IsError.java
src/java/org/apache/poi/hssf/record/formula/functions/IsNa.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Isblank.java
src/java/org/apache/poi/hssf/record/formula/functions/Iserr.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Islogical.java
src/java/org/apache/poi/hssf/record/formula/functions/Isnontext.java
src/java/org/apache/poi/hssf/record/formula/functions/Isnumber.java
src/java/org/apache/poi/hssf/record/formula/functions/Ispmt.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Isref.java
src/java/org/apache/poi/hssf/record/formula/functions/Istext.java
src/java/org/apache/poi/hssf/record/formula/functions/Kurt.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Lasterror.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Leftb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Lenb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Linest.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Links.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Logest.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/LogicalFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/Loginv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Lognormdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Lookup.java
src/java/org/apache/poi/hssf/record/formula/functions/LookupUtils.java
src/java/org/apache/poi/hssf/record/formula/functions/Match.java
src/java/org/apache/poi/hssf/record/formula/functions/MathX.java
src/java/org/apache/poi/hssf/record/formula/functions/Mdeterm.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Midb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/MinaMaxa.java
src/java/org/apache/poi/hssf/record/formula/functions/Minute.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Minverse.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Mirr.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Mmult.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Mode.java
src/java/org/apache/poi/hssf/record/formula/functions/MultiOperandNumericFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/N.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Na.java
src/java/org/apache/poi/hssf/record/formula/functions/Names.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Negbinomdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Normdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Norminv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Normsdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Normsinv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Not.java
src/java/org/apache/poi/hssf/record/formula/functions/NotImplementedFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/Note.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Now.java
src/java/org/apache/poi/hssf/record/formula/functions/Npv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Numberstring.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/NumericFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/Odd.java
src/java/org/apache/poi/hssf/record/formula/functions/Offset.java
src/java/org/apache/poi/hssf/record/formula/functions/Or.java
src/java/org/apache/poi/hssf/record/formula/functions/Pearson.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Percentile.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Percentrank.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Permut.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Pi.java
src/java/org/apache/poi/hssf/record/formula/functions/Poisson.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Ppmt.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Prob.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Proper.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Quartile.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Rand.java
src/java/org/apache/poi/hssf/record/formula/functions/Rank.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Rate.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Reftext.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Relref.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Replace.java
src/java/org/apache/poi/hssf/record/formula/functions/Replaceb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Rept.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Request.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Result.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Rightb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Roman.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Row.java
src/java/org/apache/poi/hssf/record/formula/functions/Rows.java
src/java/org/apache/poi/hssf/record/formula/functions/Rsq.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Search.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Searchb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Second.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Series.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Setname.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Setvalue.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Skew.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Sln.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Slope.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Standardize.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/StatsLib.java
src/java/org/apache/poi/hssf/record/formula/functions/Stdeva.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Stdevp.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Stdevpa.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Step.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Steyx.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Substitute.java
src/java/org/apache/poi/hssf/record/formula/functions/Subtotal.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Sumif.java
src/java/org/apache/poi/hssf/record/formula/functions/Sumproduct.java
src/java/org/apache/poi/hssf/record/formula/functions/Sumx2my2.java
src/java/org/apache/poi/hssf/record/formula/functions/Sumx2py2.java
src/java/org/apache/poi/hssf/record/formula/functions/Sumxmy2.java
src/java/org/apache/poi/hssf/record/formula/functions/Syd.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/T.java
src/java/org/apache/poi/hssf/record/formula/functions/Tdist.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Text.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/TextFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/Textref.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Time.java
src/java/org/apache/poi/hssf/record/formula/functions/Timevalue.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Tinv.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Today.java
src/java/org/apache/poi/hssf/record/formula/functions/Transpose.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Trend.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Trimmean.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/True.java
src/java/org/apache/poi/hssf/record/formula/functions/Trunc.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Ttest.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Type.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Usdollar.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Value.java
src/java/org/apache/poi/hssf/record/formula/functions/Var.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Vara.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Varp.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Varpa.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Vdb.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Vlookup.java
src/java/org/apache/poi/hssf/record/formula/functions/Volatile.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Weekday.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/Weibull.java [deleted file]
src/java/org/apache/poi/hssf/record/formula/functions/XYNumericFunction.java
src/java/org/apache/poi/hssf/record/formula/functions/Ztest.java [deleted file]
src/testcases/org/apache/poi/hssf/record/formula/functions/TestMathX.java

index 12da871e6d79b8e3fb36a464fa78a7b34b1d19d2..ef7f39a6b0abdc5c9137843fbe30a127bd00a1d9 100644 (file)
@@ -20,6 +20,7 @@ package org.apache.poi.hssf.record.formula.eval;
 import java.util.HashMap;
 import java.util.Map;
 
+import org.apache.poi.hssf.record.formula.function.FunctionMetadata;
 import org.apache.poi.hssf.record.formula.function.FunctionMetadataRegistry;
 import org.apache.poi.hssf.record.formula.functions.*;
 
@@ -28,404 +29,220 @@ import org.apache.poi.hssf.record.formula.functions.*;
  *  
  */
 public abstract class FunctionEval implements OperationEval {
-    /**
-     * Some function IDs that require special treatment
-     */
-    private static final class FunctionID {
-        /** 4 */
-        public static final int SUM = FunctionMetadataRegistry.FUNCTION_INDEX_SUM;
-        /** 78 */
-        public static final int OFFSET = 78;
-        /** 148 */
-        public static final int INDIRECT = 148;
-        /** 255 */
-        public static final int EXTERNAL_FUNC = FunctionMetadataRegistry.FUNCTION_INDEX_EXTERNAL;
-    }
-    // convenient access to namespace
-    private static final FunctionID ID = null;
-    
-    protected static Function[] functions = produceFunctions();
-
-    private static Map<Integer, FreeRefFunction> freeRefFunctionsByIdMap;
-     
-    static {
-        Map<Integer, FreeRefFunction> m = new HashMap<Integer, FreeRefFunction>();
-        m.put(createFRFKey(ID.INDIRECT), new Indirect());
-        m.put(createFRFKey(ID.EXTERNAL_FUNC), new ExternalFunction());
-        freeRefFunctionsByIdMap = m;
-    }
-    private static Integer createFRFKey(int functionIndex) {
-        return new Integer(functionIndex);
-    }
-    
-    
-    public Function getFunction() {
-        short fidx = getFunctionIndex();
-        return functions[fidx];
-    }
-    public boolean isFreeRefFunction() {
-        return freeRefFunctionsByIdMap.containsKey(createFRFKey(getFunctionIndex()));
-    }
-    public FreeRefFunction getFreeRefFunction() {
-        return freeRefFunctionsByIdMap.get(createFRFKey(getFunctionIndex()));
-    }
-
-    public abstract short getFunctionIndex();
-
-    private static Function[] produceFunctions() {
-        Function[] retval = new Function[368];
-        retval[0] = new Count(); // COUNT
-        retval[1] = new If(); // IF
-        retval[2] = new IsNa(); // ISNA
-        retval[3] = new IsError(); // ISERROR
-        retval[ID.SUM] = AggregateFunction.SUM;
-        retval[5] = AggregateFunction.AVERAGE;
-        retval[6] = AggregateFunction.MIN;
-        retval[7] = AggregateFunction.MAX;
-        retval[8] = new Row(); // ROW
-        retval[9] = new Column(); // COLUMN
-        retval[10] = new Na(); // NA
-        retval[11] = new Npv(); // NPV
-        retval[12] = AggregateFunction.STDEV;
-        retval[13] = NumericFunction.DOLLAR;
-        retval[14] = new Fixed(); // FIXED
-        retval[15] = NumericFunction.SIN;
-        retval[16] = NumericFunction.COS;
-        retval[17] = NumericFunction.TAN;
-        retval[18] = NumericFunction.ATAN;
-        retval[19] = new Pi(); // PI
-        retval[20] = NumericFunction.SQRT;
-        retval[21] = NumericFunction.EXP;
-        retval[22] = NumericFunction.LN;
-        retval[23] = NumericFunction.LOG10;
-        retval[24] = NumericFunction.ABS;
-        retval[25] = NumericFunction.INT;
-        retval[26] = NumericFunction.SIGN;
-        retval[27] = NumericFunction.ROUND;
-        retval[28] = new Lookup(); // LOOKUP
-        retval[29] = new Index(); // INDEX
-        retval[30] = new Rept(); // REPT
-        retval[31] = TextFunction.MID;
-        retval[32] = TextFunction.LEN;
-        retval[33] = new Value(); // VALUE
-        retval[34] = new True(); // TRUE
-        retval[35] = new False(); // FALSE
-        retval[36] = new And(); // AND
-        retval[37] = new Or(); // OR
-        retval[38] = new Not(); // NOT
-        retval[39] = NumericFunction.MOD;
-        retval[40] = new Dcount(); // DCOUNT
-        retval[41] = new Dsum(); // DSUM
-        retval[42] = new Daverage(); // DAVERAGE
-        retval[43] = new Dmin(); // DMIN
-        retval[44] = new Dmax(); // DMAX
-        retval[45] = new Dstdev(); // DSTDEV
-        retval[46] = new Var(); // VAR
-        retval[47] = new Dvar(); // DVAR
-        retval[48] = new Text(); // TEXT
-        retval[49] = new Linest(); // LINEST
-        retval[50] = new Trend(); // TREND
-        retval[51] = new Logest(); // LOGEST
-        retval[52] = new Growth(); // GROWTH
-        retval[53] = new Goto(); // GOTO
-        retval[54] = new Halt(); // HALT
-        retval[56] = FinanceFunction.PV;
-        retval[57] = FinanceFunction.FV;
-        retval[58] = FinanceFunction.NPER;
-        retval[59] = FinanceFunction.PMT;
-        retval[60] = new Rate(); // RATE
-        retval[61] = new Mirr(); // MIRR
-        retval[62] = new Irr(); // IRR
-        retval[63] = new Rand(); // RAND
-        retval[64] = new Match(); // MATCH
-        retval[65] = DateFunc.instance; // DATE
-        retval[66] = new Time(); // TIME
-        retval[67] = CalendarFieldFunction.DAY; // DAY
-        retval[68] = CalendarFieldFunction.MONTH; // MONTH
-        retval[69] = CalendarFieldFunction.YEAR; // YEAR
-        retval[70] = new Weekday(); // WEEKDAY
-        retval[71] = new Hour(); // HOUR
-        retval[72] = new Minute(); // MINUTE
-        retval[73] = new Second(); // SECOND
-        retval[74] = new Now(); // NOW
-        retval[75] = new Areas(); // AREAS
-        retval[76] = new Rows(); // ROWS
-        retval[77] = new Columns(); // COLUMNS
-        retval[ID.OFFSET] = new Offset(); // OFFSET
-        retval[79] = new Absref(); // ABSREF
-        retval[80] = new Relref(); // RELREF
-        retval[81] = new Argument(); // ARGUMENT
-        retval[82] = new Search(); // SEARCH
-        retval[83] = new Transpose(); // TRANSPOSE
-        retval[84] = new org.apache.poi.hssf.record.formula.functions.Error(); // ERROR
-        retval[85] = new Step(); // STEP
-        retval[86] = new Type(); // TYPE
-        retval[87] = new Echo(); // ECHO
-        retval[88] = new Setname(); // SETNAME
-        retval[89] = new Caller(); // CALLER
-        retval[90] = new Deref(); // DEREF
-        retval[91] = new NotImplementedFunction("WINDOWS");
-        retval[92] = new Series(); // SERIES
-        retval[93] = new NotImplementedFunction("DOCUMENTS");
-        retval[94] = new Activecell(); // ACTIVECELL
-        retval[95] = new NotImplementedFunction("SELECTION");
-        retval[96] = new Result(); // RESULT
-        retval[97] = NumericFunction.ATAN2;
-        retval[98] = NumericFunction.ASIN;
-        retval[99] = NumericFunction.ACOS;
-        retval[100] = new Choose(); // CHOOSE
-        retval[101] = new Hlookup(); // HLOOKUP
-        retval[102] = new Vlookup(); // VLOOKUP
-        retval[103] = new Links(); // LINKS
-        retval[104] = new Input(); // INPUT
-        retval[105] = new Isref(); // ISREF
-        retval[106] = new NotImplementedFunction("GETFORMULA");
-        retval[107] = new NotImplementedFunction("GETNAME");
-        retval[108] = new Setvalue(); // SETVALUE
-        retval[109] = NumericFunction.LOG;
-        retval[110] = new Exec(); // EXEC
-        retval[111] = new Char(); // CHAR
-        retval[112] = TextFunction.LOWER;
-        retval[113] = TextFunction.UPPER;
-        retval[114] = new Proper(); // PROPER
-        retval[115] = TextFunction.LEFT;
-        retval[116] = TextFunction.RIGHT;
-        retval[117] = TextFunction.EXACT;
-        retval[118] = TextFunction.TRIM;
-        retval[119] = new Replace(); // REPLACE
-        retval[120] = new Substitute(); // SUBSTITUTE
-        retval[121] = new Code(); // CODE
-        retval[122] = new Names(); // NAMES
-        retval[123] = new NotImplementedFunction("DIRECTORY");
-        retval[124] = new Find(); // FIND
-        retval[125] = new Cell(); // CELL
-        retval[126] = new Iserr(); // ISERR
-        retval[127] = new Istext(); // ISTEXT
-        retval[128] = new Isnumber(); // ISNUMBER
-        retval[129] = new Isblank(); // ISBLANK
-        retval[130] = new T(); // T
-        retval[131] = new N(); // N
-        retval[132] = new NotImplementedFunction("FOPEN");
-        retval[133] = new NotImplementedFunction("FCLOSE");
-        retval[134] = new NotImplementedFunction("FSIZE");
-        retval[135] = new NotImplementedFunction("FREADLN");
-        retval[136] = new NotImplementedFunction("FREAD");
-        retval[137] = new NotImplementedFunction("FWRITELN");
-        retval[138] = new NotImplementedFunction("FWRITE");
-        retval[139] = new Fpos(); // FPOS
-        retval[140] = new Datevalue(); // DATEVALUE
-        retval[141] = new Timevalue(); // TIMEVALUE
-        retval[142] = new Sln(); // SLN
-        retval[143] = new Syd(); // SYD
-        retval[144] = new Ddb(); // DDB
-        retval[145] = new NotImplementedFunction("GETDEF");
-        retval[146] = new Reftext(); // REFTEXT
-        retval[147] = new Textref(); // TEXTREF
-        retval[ID.INDIRECT] = null; // Indirect.evaluate has different signature
-        retval[149] = new NotImplementedFunction("REGISTER");
-        retval[150] = new Call(); // CALL
-        retval[151] = new NotImplementedFunction("ADDBAR");
-        retval[152] = new NotImplementedFunction("ADDMENU");
-        retval[153] = new NotImplementedFunction("ADDCOMMAND");
-        retval[154] = new NotImplementedFunction("ENABLECOMMAND");
-        retval[155] = new NotImplementedFunction("CHECKCOMMAND");
-        retval[156] = new NotImplementedFunction("RENAMECOMMAND");
-        retval[157] = new NotImplementedFunction("SHOWBAR");
-        retval[158] = new NotImplementedFunction("DELETEMENU");
-        retval[159] = new NotImplementedFunction("DELETECOMMAND");
-        retval[160] = new NotImplementedFunction("GETCHARTITEM");
-        retval[161] = new NotImplementedFunction("DIALOGBOX");
-        retval[162] = new Clean(); // CLEAN
-        retval[163] = new Mdeterm(); // MDETERM
-        retval[164] = new Minverse(); // MINVERSE
-        retval[165] = new Mmult(); // MMULT
-        retval[166] = new Files(); // FILES
-        retval[167] = new Ipmt(); // IPMT
-        retval[168] = new Ppmt(); // PPMT
-        retval[169] = new Counta(); // COUNTA
-        retval[170] = new NotImplementedFunction("CANCELKEY");
-        retval[175] = new Initiate(); // INITIATE
-        retval[176] = new Request(); // REQUEST
-        retval[177] = new NotImplementedFunction("POKE");
-        retval[178] = new NotImplementedFunction("EXECUTE");
-        retval[179] = new NotImplementedFunction("TERMINATE");
-        retval[180] = new NotImplementedFunction("RESTART");
-        retval[181] = new Help(); // HELP
-        retval[182] = new NotImplementedFunction("GETBAR");
-        retval[183] = AggregateFunction.PRODUCT;
-        retval[184] = NumericFunction.FACT;
-        retval[185] = new NotImplementedFunction("GETCELL");
-        retval[186] = new NotImplementedFunction("GETWORKSPACE");
-        retval[187] = new NotImplementedFunction("GETWINDOW");
-        retval[188] = new NotImplementedFunction("GETDOCUMENT");
-        retval[189] = new Dproduct(); // DPRODUCT
-        retval[190] = new Isnontext(); // ISNONTEXT
-        retval[191] = new NotImplementedFunction("GETNOTE");
-        retval[192] = new Note(); // NOTE
-        retval[193] = new Stdevp(); // STDEVP
-        retval[194] = new Varp(); // VARP
-        retval[195] = new Dstdevp(); // DSTDEVP
-        retval[196] = new Dvarp(); // DVARP
-        retval[197] = new Trunc(); // TRUNC
-        retval[198] = new Islogical(); // ISLOGICAL
-        retval[199] = new Dcounta(); // DCOUNTA
-        retval[200] = new NotImplementedFunction("DELETEBAR");
-        retval[201] = new NotImplementedFunction("UNREGISTER");
-        retval[204] = new Usdollar(); // USDOLLAR
-        retval[205] = new Findb(); // FINDB
-        retval[206] = new Searchb(); // SEARCHB
-        retval[207] = new Replaceb(); // REPLACEB
-        retval[208] = new Leftb(); // LEFTB
-        retval[209] = new Rightb(); // RIGHTB
-        retval[210] = new Midb(); // MIDB
-        retval[211] = new Lenb(); // LENB
-        retval[212] = NumericFunction.ROUNDUP;
-        retval[213] = NumericFunction.ROUNDDOWN;
-        retval[214] = new Asc(); // ASC
-        retval[215] = new Dbcs(); // DBCS
-        retval[216] = new Rank(); // RANK
-        retval[219] = new Address(); // ADDRESS
-        retval[220] = new Days360(); // DAYS360
-        retval[221] = new Today(); // TODAY
-        retval[222] = new Vdb(); // VDB
-        retval[227] = AggregateFunction.MEDIAN;
-        retval[228] = new Sumproduct(); // SUMPRODUCT
-        retval[229] = NumericFunction.SINH;
-        retval[230] = NumericFunction.COSH;
-        retval[231] = NumericFunction.TANH;
-        retval[232] = NumericFunction.ASINH;
-        retval[233] = NumericFunction.ACOSH;
-        retval[234] = NumericFunction.ATANH;
-        retval[235] = new Dget(); // DGET
-        retval[236] = new NotImplementedFunction("CREATEOBJECT");
-        retval[237] = new Volatile(); // VOLATILE
-        retval[238] = new Lasterror(); // LASTERROR
-        retval[239] = new NotImplementedFunction("CUSTOMUNDO");
-        retval[240] = new Customrepeat(); // CUSTOMREPEAT
-        retval[241] = new Formulaconvert(); // FORMULACONVERT
-        retval[242] = new NotImplementedFunction("GETLINKINFO");
-        retval[243] = new NotImplementedFunction("TEXTBOX");
-        retval[244] = new Info(); // INFO
-        retval[245] = new Group(); // GROUP
-        retval[246] = new NotImplementedFunction("GETOBJECT");
-        retval[247] = new Db(); // DB
-        retval[248] = new NotImplementedFunction("PAUSE");
-        retval[250] = new NotImplementedFunction("RESUME");
-        retval[252] = new Frequency(); // FREQUENCY
-        retval[253] = new NotImplementedFunction("ADDTOOLBAR");
-        retval[254] = new NotImplementedFunction("DELETETOOLBAR");
-        retval[ID.EXTERNAL_FUNC] = null; // ExternalFunction is a FreeREfFunction
-        retval[256] = new NotImplementedFunction("RESETTOOLBAR");
-        retval[257] = new Evaluate(); // EVALUATE
-        retval[258] = new NotImplementedFunction("GETTOOLBAR");
-        retval[259] = new NotImplementedFunction("GETTOOL");
-        retval[260] = new NotImplementedFunction("SPELLINGCHECK");
-        retval[261] = new Errortype(); // ERRORTYPE
-        retval[262] = new NotImplementedFunction("APPTITLE");
-        retval[263] = new NotImplementedFunction("WINDOWTITLE");
-        retval[264] = new NotImplementedFunction("SAVETOOLBAR");
-        retval[265] = new NotImplementedFunction("ENABLETOOL");
-        retval[266] = new NotImplementedFunction("PRESSTOOL");
-        retval[267] = new NotImplementedFunction("REGISTERID");
-        retval[268] = new NotImplementedFunction("GETWORKBOOK");
-        retval[269] = AggregateFunction.AVEDEV;
-        retval[270] = new Betadist(); // BETADIST
-        retval[271] = new Gammaln(); // GAMMALN
-        retval[272] = new Betainv(); // BETAINV
-        retval[273] = new Binomdist(); // BINOMDIST
-        retval[274] = new Chidist(); // CHIDIST
-        retval[275] = new Chiinv(); // CHIINV
-        retval[276] = NumericFunction.COMBIN;
-        retval[277] = new Confidence(); // CONFIDENCE
-        retval[278] = new Critbinom(); // CRITBINOM
-        retval[279] = new Even(); // EVEN
-        retval[280] = new Expondist(); // EXPONDIST
-        retval[281] = new Fdist(); // FDIST
-        retval[282] = new Finv(); // FINV
-        retval[283] = new Fisher(); // FISHER
-        retval[284] = new Fisherinv(); // FISHERINV
-        retval[285] = NumericFunction.FLOOR;
-        retval[286] = new Gammadist(); // GAMMADIST
-        retval[287] = new Gammainv(); // GAMMAINV
-        retval[288] = NumericFunction.CEILING;
-        retval[289] = new Hypgeomdist(); // HYPGEOMDIST
-        retval[290] = new Lognormdist(); // LOGNORMDIST
-        retval[291] = new Loginv(); // LOGINV
-        retval[292] = new Negbinomdist(); // NEGBINOMDIST
-        retval[293] = new Normdist(); // NORMDIST
-        retval[294] = new Normsdist(); // NORMSDIST
-        retval[295] = new Norminv(); // NORMINV
-        retval[296] = new Normsinv(); // NORMSINV
-        retval[297] = new Standardize(); // STANDARDIZE
-        retval[298] = new Odd(); // ODD
-        retval[299] = new Permut(); // PERMUT
-        retval[300] = new Poisson(); // POISSON
-        retval[301] = new Tdist(); // TDIST
-        retval[302] = new Weibull(); // WEIBULL
-        retval[303] = new Sumxmy2(); // SUMXMY2
-        retval[304] = new Sumx2my2(); // SUMX2MY2
-        retval[305] = new Sumx2py2(); // SUMX2PY2
-        retval[306] = new Chitest(); // CHITEST
-        retval[307] = new Correl(); // CORREL
-        retval[308] = new Covar(); // COVAR
-        retval[309] = new Forecast(); // FORECAST
-        retval[310] = new Ftest(); // FTEST
-        retval[311] = new Intercept(); // INTERCEPT
-        retval[312] = new Pearson(); // PEARSON
-        retval[313] = new Rsq(); // RSQ
-        retval[314] = new Steyx(); // STEYX
-        retval[315] = new Slope(); // SLOPE
-        retval[316] = new Ttest(); // TTEST
-        retval[317] = new Prob(); // PROB
-        retval[318] = AggregateFunction.DEVSQ;
-        retval[319] = new Geomean(); // GEOMEAN
-        retval[320] = new Harmean(); // HARMEAN
-        retval[321] = AggregateFunction.SUMSQ;
-        retval[322] = new Kurt(); // KURT
-        retval[323] = new Skew(); // SKEW
-        retval[324] = new Ztest(); // ZTEST
-        retval[325] = AggregateFunction.LARGE;
-        retval[326] = AggregateFunction.SMALL;
-        retval[327] = new Quartile(); // QUARTILE
-        retval[328] = new Percentile(); // PERCENTILE
-        retval[329] = new Percentrank(); // PERCENTRANK
-        retval[330] = new Mode(); // MODE
-        retval[331] = new Trimmean(); // TRIMMEAN
-        retval[332] = new Tinv(); // TINV
-        retval[334] = new NotImplementedFunction("MOVIECOMMAND");
-        retval[335] = new NotImplementedFunction("GETMOVIE");
-        retval[336] = TextFunction.CONCATENATE;
-        retval[337] = NumericFunction.POWER;
-        retval[338] = new NotImplementedFunction("PIVOTADDDATA");
-        retval[339] = new NotImplementedFunction("GETPIVOTTABLE");
-        retval[340] = new NotImplementedFunction("GETPIVOTFIELD");
-        retval[341] = new NotImplementedFunction("GETPIVOTITEM");
-        retval[342] = NumericFunction.RADIANS;
-        retval[343] = NumericFunction.DEGREES;
-        retval[344] = new Subtotal(); // SUBTOTAL
-        retval[345] = new Sumif(); // SUMIF
-        retval[346] = new Countif(); // COUNTIF
-        retval[347] = new Countblank(); // COUNTBLANK
-        retval[348] = new NotImplementedFunction("SCENARIOGET");
-        retval[349] = new NotImplementedFunction("OPTIONSLISTSGET");
-        retval[350] = new Ispmt(); // ISPMT
-        retval[351] = new Datedif(); // DATEDIF
-        retval[352] = new Datestring(); // DATESTRING
-        retval[353] = new Numberstring(); // NUMBERSTRING
-        retval[354] = new Roman(); // ROMAN
-        retval[355] = new NotImplementedFunction("OPENDIALOG");
-        retval[356] = new NotImplementedFunction("SAVEDIALOG");
-        retval[357] = new NotImplementedFunction("VIEWGET");
-        retval[358] = new NotImplementedFunction("GETPIVOTDATA");
-        retval[359] = new Hyperlink(); // HYPERLINK
-        retval[360] = new NotImplementedFunction("PHONETIC");
-        retval[361] = new Averagea(); // AVERAGEA
-        retval[362] = MinaMaxa.MAXA;
-        retval[363] = MinaMaxa.MINA;
-        retval[364] = new Stdevpa(); // STDEVPA
-        retval[365] = new Varpa(); // VARPA
-        retval[366] = new Stdeva(); // STDEVA
-        retval[367] = new Vara(); // VARA
-        return retval;
-    }
+       /**
+        * Some function IDs that require special treatment
+        */
+       private static final class FunctionID {
+               /** 4 */
+               public static final int SUM = FunctionMetadataRegistry.FUNCTION_INDEX_SUM;
+               /** 78 */
+               public static final int OFFSET = 78;
+               /** 148 */
+               public static final int INDIRECT = 148;
+               /** 255 */
+               public static final int EXTERNAL_FUNC = FunctionMetadataRegistry.FUNCTION_INDEX_EXTERNAL;
+       }
+       // convenient access to namespace
+       private static final FunctionID ID = null;
+
+       protected static final Function[] functions ;
+
+       private static Map<Integer, FreeRefFunction> freeRefFunctionsByIdMap;
+
+       static {
+               Map<Integer, FreeRefFunction> m = new HashMap<Integer, FreeRefFunction>();
+               m.put(createFRFKey(ID.INDIRECT), new Indirect());
+               m.put(createFRFKey(ID.EXTERNAL_FUNC), new ExternalFunction());
+               freeRefFunctionsByIdMap = m;
+               functions = produceFunctions();
+       }
+       private static Integer createFRFKey(int functionIndex) {
+               return new Integer(functionIndex);
+       }
+
+
+       public Function getFunction() {
+               short fidx = getFunctionIndex();
+               return functions[fidx];
+       }
+       public boolean isFreeRefFunction() {
+               return freeRefFunctionsByIdMap.containsKey(createFRFKey(getFunctionIndex()));
+       }
+       public FreeRefFunction getFreeRefFunction() {
+               return freeRefFunctionsByIdMap.get(createFRFKey(getFunctionIndex()));
+       }
+
+       public abstract short getFunctionIndex();
+
+       private static Function[] produceFunctions() {
+               Function[] retval = new Function[368];
+
+               retval[0] = new Count();
+               retval[1] = new If();
+
+               retval[3] = new IsError();
+               retval[ID.SUM] = AggregateFunction.SUM;
+               retval[5] = AggregateFunction.AVERAGE;
+               retval[6] = AggregateFunction.MIN;
+               retval[7] = AggregateFunction.MAX;
+               retval[8] = new Row(); // ROW
+               retval[9] = new Column();
+               retval[10] = new Na();
+
+               retval[12] = AggregateFunction.STDEV;
+               retval[13] = NumericFunction.DOLLAR;
+
+               retval[15] = NumericFunction.SIN;
+               retval[16] = NumericFunction.COS;
+               retval[17] = NumericFunction.TAN;
+               retval[18] = NumericFunction.ATAN;
+               retval[19] = new Pi();
+               retval[20] = NumericFunction.SQRT;
+               retval[21] = NumericFunction.EXP;
+               retval[22] = NumericFunction.LN;
+               retval[23] = NumericFunction.LOG10;
+               retval[24] = NumericFunction.ABS;
+               retval[25] = NumericFunction.INT;
+               retval[26] = NumericFunction.SIGN;
+               retval[27] = NumericFunction.ROUND;
+               retval[28] = new Lookup();
+               retval[29] = new Index();
+
+               retval[31] = TextFunction.MID;
+               retval[32] = TextFunction.LEN;
+               retval[33] = new Value();
+               retval[34] = new True();
+               retval[35] = new False();
+               retval[36] = new And();
+               retval[37] = new Or();
+               retval[38] = new Not();
+               retval[39] = NumericFunction.MOD;
+
+               retval[56] = FinanceFunction.PV;
+               retval[57] = FinanceFunction.FV;
+               retval[58] = FinanceFunction.NPER;
+               retval[59] = FinanceFunction.PMT;
+
+               retval[63] = new Rand();
+               retval[64] = new Match();
+               retval[65] = DateFunc.instance;
+               retval[66] = new Time();
+               retval[67] = CalendarFieldFunction.DAY;
+               retval[68] = CalendarFieldFunction.MONTH;
+               retval[69] = CalendarFieldFunction.YEAR;
+
+               retval[74] = new Now();
+
+               retval[76] = new Rows();
+               retval[77] = new Columns();
+               retval[ID.OFFSET] = new Offset();
+
+               retval[97] = NumericFunction.ATAN2;
+               retval[98] = NumericFunction.ASIN;
+               retval[99] = NumericFunction.ACOS;
+               retval[100] = new Choose();
+               retval[101] = new Hlookup();
+               retval[102] = new Vlookup();
+
+               retval[105] = new Isref();
+
+               retval[109] = NumericFunction.LOG;
+
+               retval[112] = TextFunction.LOWER;
+               retval[113] = TextFunction.UPPER;
+
+               retval[115] = TextFunction.LEFT;
+               retval[116] = TextFunction.RIGHT;
+               retval[117] = TextFunction.EXACT;
+               retval[118] = TextFunction.TRIM;
+               retval[119] = new Replace();
+               retval[120] = new Substitute();
+
+               retval[124] = new Find();
+
+               retval[127] = new Istext();
+               retval[128] = new Isnumber();
+               retval[129] = new Isblank();
+               retval[130] = new T();
+
+               retval[ID.INDIRECT] = null; // Indirect.evaluate has different signature
+
+               retval[169] = new Counta();
+
+               retval[183] = AggregateFunction.PRODUCT;
+               retval[184] = NumericFunction.FACT;
+
+               retval[190] = new Isnontext();
+
+               retval[198] = new Islogical();
+
+               retval[212] = NumericFunction.ROUNDUP;
+               retval[213] = NumericFunction.ROUNDDOWN;
+
+               retval[221] = new Today();
+
+               retval[227] = AggregateFunction.MEDIAN;
+               retval[228] = new Sumproduct();
+               retval[229] = NumericFunction.SINH;
+               retval[230] = NumericFunction.COSH;
+               retval[231] = NumericFunction.TANH;
+               retval[232] = NumericFunction.ASINH;
+               retval[233] = NumericFunction.ACOSH;
+               retval[234] = NumericFunction.ATANH;
+
+               retval[ID.EXTERNAL_FUNC] = null; // ExternalFunction is a FreeREfFunction
+
+               retval[261] = new Errortype();
+
+               retval[269] = AggregateFunction.AVEDEV;
+
+               retval[276] = NumericFunction.COMBIN;
+
+               retval[279] = new Even();
+
+               retval[285] = NumericFunction.FLOOR;
+
+               retval[288] = NumericFunction.CEILING;
+
+               retval[298] = new Odd();
+
+               retval[303] = new Sumxmy2();
+               retval[304] = new Sumx2my2();
+               retval[305] = new Sumx2py2();
+
+               retval[318] = AggregateFunction.DEVSQ;
+
+               retval[321] = AggregateFunction.SUMSQ;
+
+               retval[325] = AggregateFunction.LARGE;
+               retval[326] = AggregateFunction.SMALL;
+
+               retval[330] = new Mode();
+
+               retval[336] = TextFunction.CONCATENATE;
+               retval[337] = NumericFunction.POWER;
+
+               retval[342] = NumericFunction.RADIANS;
+               retval[343] = NumericFunction.DEGREES;
+
+               retval[345] = new Sumif();
+               retval[346] = new Countif();
+
+               retval[359] = new Hyperlink();
+
+               retval[362] = MinaMaxa.MAXA;
+               retval[363] = MinaMaxa.MINA;
+
+               for (int i = 0; i < retval.length; i++) {
+                       Function f = retval[i];
+                       if (f == null) {
+                               FunctionMetadata fm = FunctionMetadataRegistry.getFunctionByIndex(i);
+                               if (fm == null) {
+                                       continue;
+                               }
+                               retval[i] = new NotImplementedFunction(fm.getName());
+                       }
+               }
+               return retval;
+       }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Absref.java b/src/java/org/apache/poi/hssf/record/formula/functions/Absref.java
deleted file mode 100644 (file)
index 3a6e94a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Absref extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Activecell.java b/src/java/org/apache/poi/hssf/record/formula/functions/Activecell.java
deleted file mode 100644 (file)
index 17b0413..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Activecell extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Address.java b/src/java/org/apache/poi/hssf/record/formula/functions/Address.java
deleted file mode 100644 (file)
index 9b408e0..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Address extends NotImplementedFunction {
-
-}
index 0495ee3fc4d89253539b2c792bba93308706b763..6397ea39f5375fc49de980f68bf3e867e4daa545 100644 (file)
@@ -30,8 +30,6 @@ public abstract class AggregateFunction extends MultiOperandNumericFunction {
                super(false, false);
        }
 
-       /* ---------------------------------------------------------------------- */
-
        public static final Function AVEDEV = new AggregateFunction() {
                protected double evaluate(double[] values) {
                        return StatsLib.avedev(values);
index 8ef99f890407a756a36bac1d2f928c1c06696101..e024562865bb3d52687576877e4807883f65048a 100644 (file)
@@ -18,7 +18,7 @@
 package org.apache.poi.hssf.record.formula.functions;
 
 /**
- * 
+ *
  */
 public final class And extends BooleanFunction {
 
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Areas.java b/src/java/org/apache/poi/hssf/record/formula/functions/Areas.java
deleted file mode 100644 (file)
index a54b3e7..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Areas extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Argument.java b/src/java/org/apache/poi/hssf/record/formula/functions/Argument.java
deleted file mode 100644 (file)
index d07b6d6..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Argument extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Asc.java b/src/java/org/apache/poi/hssf/record/formula/functions/Asc.java
deleted file mode 100644 (file)
index 295aba2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Asc extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Averagea.java b/src/java/org/apache/poi/hssf/record/formula/functions/Averagea.java
deleted file mode 100644 (file)
index e9eb83e..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-
-/**
- * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; 
- *
- */
-public class Averagea extends NotImplementedFunction {
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Betadist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Betadist.java
deleted file mode 100644 (file)
index 87992f2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Betadist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Betainv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Betainv.java
deleted file mode 100644 (file)
index 219eaf5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Betainv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Binomdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Binomdist.java
deleted file mode 100644 (file)
index 6a13a25..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Binomdist extends NotImplementedFunction {
-
-}
index 9ec924e27a2b7f81843ccb2b7f231d2c5f252be6..4995599ea5e9bd6b8fe39201d58b2b4b83db1633 100644 (file)
@@ -30,11 +30,11 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
  * Here are the general rules concerning Boolean functions:
  * <ol>
  * <li> Blanks are ignored (not either true or false) </li>
- * <li> Strings are ignored if part of an area ref or cell ref, otherwise they must be 'true' or 'false'</li> 
+ * <li> Strings are ignored if part of an area ref or cell ref, otherwise they must be 'true' or 'false'</li>
  * <li> Numbers: 0 is false. Any other number is TRUE </li>
  * <li> Areas: *all* cells in area are evaluated according to the above rules</li>
  * </ol>
- * 
+ *
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  */
 public abstract class BooleanFunction implements Function {
@@ -56,7 +56,7 @@ public abstract class BooleanFunction implements Function {
 
                boolean result = getInitialResultValue();
                boolean atleastOneNonBlank = false;
-               
+
                /*
                 * Note: no short-circuit boolean loop exit because any ErrorEvals will override the result
                 */
@@ -88,21 +88,21 @@ public abstract class BooleanFunction implements Function {
                        } else {
                                throw new RuntimeException("Unexpected eval (" + arg.getClass().getName() + ")");
                        }
-                       
-                       
+
+
                        if (tempVe != null) {
                                result = partialEvaluate(result, tempVe.booleanValue());
                                atleastOneNonBlank = true;
                        }
                }
-               
+
                if (!atleastOneNonBlank) {
                        throw new EvaluationException(ErrorEval.VALUE_INVALID);
                }
                return result;
        }
-       
-       
+
+
        protected abstract boolean getInitialResultValue();
        protected abstract boolean partialEvaluate(boolean cumulativeResult, boolean currentValue);
 }
index b1ea02fdc072cc809df001a2e4e9447f1670273e..ce6c2b4285c3a1a0b9d46d2e154d153f6361cdd7 100644 (file)
@@ -31,16 +31,16 @@ import org.apache.poi.hssf.usermodel.HSSFDateUtil;
 
 /**
  * Implementation of Excel functions DAY, MONTH and YEAR
- * 
- * 
+ *
+ *
  * @author Guenter Kickinger g.kickinger@gmx.net
  */
 public final class CalendarFieldFunction implements Function {
-       
+
        public static final Function YEAR = new CalendarFieldFunction(Calendar.YEAR, false);
        public static final Function MONTH = new CalendarFieldFunction(Calendar.MONTH, true);
        public static final Function DAY = new CalendarFieldFunction(Calendar.DAY_OF_MONTH, false);
-       
+
        private final int _dateFieldId;
        private final boolean _needsOneBaseAdjustment;
 
@@ -89,4 +89,4 @@ public final class CalendarFieldFunction implements Function {
                }
                return result;
        }
-}
\ No newline at end of file
+}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Call.java b/src/java/org/apache/poi/hssf/record/formula/functions/Call.java
deleted file mode 100644 (file)
index a1cb4ca..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Call extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Caller.java b/src/java/org/apache/poi/hssf/record/formula/functions/Caller.java
deleted file mode 100644 (file)
index 206d08a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Caller extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Cell.java b/src/java/org/apache/poi/hssf/record/formula/functions/Cell.java
deleted file mode 100644 (file)
index ffbd322..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Cell extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Char.java b/src/java/org/apache/poi/hssf/record/formula/functions/Char.java
deleted file mode 100644 (file)
index 2c4271d..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Char extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Chidist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Chidist.java
deleted file mode 100644 (file)
index b431fe3..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Chidist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Chiinv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Chiinv.java
deleted file mode 100644 (file)
index c2d45b0..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Chiinv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Chitest.java b/src/java/org/apache/poi/hssf/record/formula/functions/Chitest.java
deleted file mode 100644 (file)
index b7065b0..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Chitest extends NotImplementedFunction {
-
-}
index 2f3ac240a902548618012658a2155e09a1bbbc3f..dbe0aa7a9b0290b7439e7bbaf0ee4e0c7570da06 100644 (file)
@@ -24,7 +24,7 @@ import org.apache.poi.hssf.record.formula.eval.OperandResolver;
 import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
- * 
+ *
  * @author Josh Micich
  */
 public final class Choose implements Function {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Clean.java b/src/java/org/apache/poi/hssf/record/formula/functions/Clean.java
deleted file mode 100644 (file)
index cc01655..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Clean extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Code.java b/src/java/org/apache/poi/hssf/record/formula/functions/Code.java
deleted file mode 100644 (file)
index e340a57..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Code extends NotImplementedFunction {
-
-}
index adde35c1623c503ec1735d1e960db83830be7045..5b04836123dcfe1ca96f9f87fbb71dab016c8c2d 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.AreaEval;
@@ -27,11 +24,11 @@ import org.apache.poi.hssf.record.formula.eval.NumberEval;
 import org.apache.poi.hssf.record.formula.eval.RefEval;
 import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
-public class Column implements Function {
+public final class Column implements Function {
     public Eval evaluate(Eval[] evals, int srcCellRow, short srcCellCol) {
         ValueEval retval = null;
         int cnum = -1;
-        
+
         switch (evals.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -51,15 +48,15 @@ public class Column implements Function {
         case 0:
             cnum = srcCellCol;
         }
-        
+
         if (retval == null) {
             retval = (cnum >= 0)
                     ? new NumberEval(cnum + 1) // +1 since excel colnums are 1 based
                     : (ValueEval) ErrorEval.VALUE_INVALID;
         }
-        
+
         return retval;
     }
-    
+
 
 }
index b75864e72d80a610166863421f1b3a69d0c3e1c2..2a57bedb2d7c60a948f1a385e60b310404526743 100644 (file)
@@ -1,20 +1,19 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
 
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
 
 package org.apache.poi.hssf.record.formula.functions;
 
@@ -26,7 +25,7 @@ import org.apache.poi.hssf.record.formula.eval.RefEval;
 
 /**
  * Implementation for Excel COLUMNS function.
- * 
+ *
  * @author Josh Micich
  */
 public final class Columns implements Function {
@@ -44,16 +43,16 @@ public final class Columns implements Function {
                                return ErrorEval.VALUE_INVALID;
                }
                Eval firstArg = args[0];
-               
+
                int result;
-        if (firstArg instanceof AreaEval) {
-            AreaEval ae = (AreaEval) firstArg;
-            result = ae.getLastColumn() - ae.getFirstColumn() + 1;
-        } else if (firstArg instanceof RefEval) {
-            result = 1;
-        } else { // anything else is not valid argument
-            return ErrorEval.VALUE_INVALID;
-        }
-        return new NumberEval(result);
+               if (firstArg instanceof AreaEval) {
+                       AreaEval ae = (AreaEval) firstArg;
+                       result = ae.getLastColumn() - ae.getFirstColumn() + 1;
+               } else if (firstArg instanceof RefEval) {
+                       result = 1;
+               } else { // anything else is not valid argument
+                       return ErrorEval.VALUE_INVALID;
+               }
+               return new NumberEval(result);
        }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Confidence.java b/src/java/org/apache/poi/hssf/record/formula/functions/Confidence.java
deleted file mode 100644 (file)
index 0d30a8d..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Confidence extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Correl.java b/src/java/org/apache/poi/hssf/record/formula/functions/Correl.java
deleted file mode 100644 (file)
index 53cf4fd..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Correl extends NotImplementedFunction {
-
-}
index 62f4b6137af05b5cf96a8d2dcb00b609b0484357..4b8b217f4da2977e51c5c45264b4f103ec97eeff 100644 (file)
@@ -25,12 +25,12 @@ import org.apache.poi.hssf.record.formula.functions.CountUtils.I_MatchPredicate;
 
 /**
  * Counts the number of cells that contain numeric data within
- *  the list of arguments. 
+ *  the list of arguments.
  *
  * Excel Syntax
  * COUNT(value1,value2,...)
  * Value1, value2, ...   are 1 to 30 arguments representing the values or ranges to be counted.
- * 
+ *
  * TODO: Check this properly matches excel on edge cases
  *  like formula cells, error cells etc
  */
@@ -47,12 +47,12 @@ public final class Count implements Function {
                        // too many arguments
                        return ErrorEval.VALUE_INVALID;
                }
-               
+
                int temp = 0;
-               
+
                for(int i=0; i<nArgs; i++) {
                        temp += CountUtils.countArg(args[i], predicate);
-                       
+
                }
                return new NumberEval(temp);
        }
@@ -74,4 +74,4 @@ public final class Count implements Function {
                        return false;
                }
        };
-}
\ No newline at end of file
+}
index 27dfcc1b64500dca97206e1efddc574432dce97f..332f7475d1bd11820cbb96ff50bf2ac8663a5dfc 100644 (file)
@@ -25,14 +25,14 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 /**
  * Common logic for COUNT, COUNTA and COUNTIF
  *
- * @author Josh Micich 
+ * @author Josh Micich
  */
 final class CountUtils {
 
        private CountUtils() {
                // no instances of this class
        }
-       
+
        /**
         * Common interface for the matching criteria.
         */
index 01fc0616d36650c0279f8c5c3fa58629dd248915..7ce7eadcb52c3c0fbe2229e1a75634743ededdfe 100644 (file)
@@ -24,12 +24,12 @@ import org.apache.poi.hssf.record.formula.eval.NumberEval;
 import org.apache.poi.hssf.record.formula.functions.CountUtils.I_MatchPredicate;
 
 /**
- * Counts the number of cells that contain data within the list of arguments. 
+ * Counts the number of cells that contain data within the list of arguments.
  *
  * Excel Syntax
  * COUNTA(value1,value2,...)
  * Value1, value2, ...   are 1 to 30 arguments representing the values or ranges to be counted.
- * 
+ *
  * @author Josh Micich
  */
 public final class Counta implements Function {
@@ -45,12 +45,12 @@ public final class Counta implements Function {
                        // too many arguments
                        return ErrorEval.VALUE_INVALID;
                }
-               
+
                int temp = 0;
-               
+
                for(int i=0; i<nArgs; i++) {
                        temp += CountUtils.countArg(args[i], predicate);
-                       
+
                }
                return new NumberEval(temp);
        }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Countblank.java b/src/java/org/apache/poi/hssf/record/formula/functions/Countblank.java
deleted file mode 100644 (file)
index cdb0713..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Countblank extends NotImplementedFunction {
-
-}
index 953a6d64f6b4dc94400da7a8ddcf8c7649fbe6d3..5b9debc28d3d1c606af39832c2e868ee6096996b 100644 (file)
@@ -41,7 +41,7 @@ import org.apache.poi.ss.usermodel.ErrorConstants;
  *      <tr><th>criteria</th><td>is used to determine which cells to count</td></tr>
  *    </table>
  * </p>
- * 
+ *
  * @author Josh Micich
  */
 public final class Countif implements Function {
@@ -121,7 +121,7 @@ public final class Countif implements Function {
                                case NE:
                                        return !cmpResult;
                        }
-                       throw new RuntimeException("Cannot call boolean evaluate on non-equality operator '" 
+                       throw new RuntimeException("Cannot call boolean evaluate on non-equality operator '"
                                        + _representation + "'");
                }
                public boolean evaluate(int cmpResult) {
@@ -135,7 +135,7 @@ public final class Countif implements Function {
                                case GT: return cmpResult >  0;
                                case GE: return cmpResult <= 0;
                        }
-                       throw new RuntimeException("Cannot call boolean evaluate on non-equality operator '" 
+                       throw new RuntimeException("Cannot call boolean evaluate on non-equality operator '"
                                        + _representation + "'");
                }
                public String toString() {
@@ -204,7 +204,7 @@ public final class Countif implements Function {
                                                return true;
                                        default:
                                                // never matches (also inconsistent with above three cases).
-                                               // for example '>5' does not match '6', 
+                                               // for example '>5' does not match '6',
                                                return false;
                                }
                                StringEval se = (StringEval)x;
@@ -244,7 +244,7 @@ public final class Countif implements Function {
                        int testValue;
                        if(x instanceof StringEval) {
                                if (true) { // change to false to observe more intuitive behaviour
-                                       // Note - Unlike with numbers, it seems that COUNTIF never matches 
+                                       // Note - Unlike with numbers, it seems that COUNTIF never matches
                                        // boolean values when the target(x) is a string
                                        return false;
                                }
@@ -387,7 +387,7 @@ public final class Countif implements Function {
                                        case ']':
                                        case '(':
                                        case ')':
-                                               // escape literal characters that would have special meaning in regex 
+                                               // escape literal characters that would have special meaning in regex
                                                sb.append("\\").append(ch);
                                                continue;
                                }
@@ -423,7 +423,7 @@ public final class Countif implements Function {
         * @return the number of evaluated cells in the range that match the specified criteria
         */
        private double countMatchingCellsInArea(Eval rangeArg, I_MatchPredicate criteriaPredicate) {
-               
+
                if (rangeArg instanceof RefEval) {
                        return CountUtils.countMatchingCell((RefEval) rangeArg, criteriaPredicate);
                } else if (rangeArg instanceof AreaEval) {
@@ -440,7 +440,7 @@ public final class Countif implements Function {
        /* package */ static I_MatchPredicate createCriteriaPredicate(Eval arg, int srcRowIndex, int srcColumnIndex) {
 
                Eval evaluatedCriteriaArg = evaluateCriteriaArg(arg, srcRowIndex, srcColumnIndex);
-               
+
                if(evaluatedCriteriaArg instanceof NumberEval) {
                        return new NumberMatcher(((NumberEval)evaluatedCriteriaArg).getNumberValue(), CmpOp.OP_NONE);
                }
@@ -457,12 +457,12 @@ public final class Countif implements Function {
                if(evaluatedCriteriaArg == BlankEval.INSTANCE) {
                        return null;
                }
-               throw new RuntimeException("Unexpected type for criteria (" 
+               throw new RuntimeException("Unexpected type for criteria ("
                                + evaluatedCriteriaArg.getClass().getName() + ")");
        }
 
        /**
-        * 
+        *
         * @return the de-referenced criteria arg (possibly {@link ErrorEval})
         */
        private static Eval evaluateCriteriaArg(Eval arg, int srcRowIndex, int srcColumnIndex) {
@@ -512,7 +512,7 @@ public final class Countif implements Function {
                return null;
        }
        /**
-        * Boolean literals ('TRUE', 'FALSE') treated similarly but NOT same as numbers. 
+        * Boolean literals ('TRUE', 'FALSE') treated similarly but NOT same as numbers.
         */
        /* package */ static Boolean parseBoolean(String strRep) {
                if (strRep.length() < 1) {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Covar.java b/src/java/org/apache/poi/hssf/record/formula/functions/Covar.java
deleted file mode 100644 (file)
index fc11889..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Covar extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Critbinom.java b/src/java/org/apache/poi/hssf/record/formula/functions/Critbinom.java
deleted file mode 100644 (file)
index 3a3d1a6..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Critbinom extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Customrepeat.java b/src/java/org/apache/poi/hssf/record/formula/functions/Customrepeat.java
deleted file mode 100644 (file)
index 4206a17..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Customrepeat extends NotImplementedFunction {
-
-}
index 6cbe8414fed2fda882ed7e47cb86880eaab4b904..8c06837168da83300304082277c4550a381cd54d 100644 (file)
@@ -28,49 +28,48 @@ import org.apache.poi.hssf.usermodel.HSSFDateUtil;
  * @author Pavel Krupets (pkrupets at palmtreebusiness dot com)
  */
 public final class DateFunc extends NumericFunction.MultiArg {
-       
+
        public static final Function instance = new DateFunc();
-       
+
        private DateFunc() {
                super(3,3);
        }
-       
+
        protected double evaluate(double[] ds) throws EvaluationException {
                int year = getYear(ds[0]);
-        int month = (int) ds[1] - 1;
-        int day = (int) ds[2];
-        
-        if (year < 0 || month < 0 || day < 0) {
-            throw new EvaluationException(ErrorEval.VALUE_INVALID);
-        }
-        
-        if (year == 1900 && month == Calendar.FEBRUARY && day == 29) {
-            return 60.0;
-        }
-        
-        if (year == 1900) {
-            if ((month == Calendar.JANUARY && day >= 60) ||
-                (month == Calendar.FEBRUARY && day >= 30))
-            {
-                day--;
-            }
-        }
-        
-        Calendar c = new GregorianCalendar();
-        
-        c.set(year, month, day, 0, 0, 0);
-        c.set(Calendar.MILLISECOND, 0);
-        
-        return HSSFDateUtil.getExcelDate(c.getTime(), false); // XXX fix 1900/1904 problem
-     }
-    
-    private static int getYear(double d) {
-        int year = (int)d;
-        
-        if (year < 0) {
-            return -1;
-        }
-        
-        return year < 1900 ? 1900 + year : year;
-    }
+               int month = (int) ds[1] - 1;
+               int day = (int) ds[2];
+
+               if (year < 0 || month < 0 || day < 0) {
+                       throw new EvaluationException(ErrorEval.VALUE_INVALID);
+               }
+
+               if (year == 1900 && month == Calendar.FEBRUARY && day == 29) {
+                       return 60.0;
+               }
+
+               if (year == 1900) {
+                       if ((month == Calendar.JANUARY && day >= 60) ||
+                                       (month == Calendar.FEBRUARY && day >= 30)) {
+                               day--;
+                       }
+               }
+
+               Calendar c = new GregorianCalendar();
+
+               c.set(year, month, day, 0, 0, 0);
+               c.set(Calendar.MILLISECOND, 0);
+
+               return HSSFDateUtil.getExcelDate(c.getTime(), false); // TODO - fix 1900/1904 problem
+       }
+
+       private static int getYear(double d) {
+               int year = (int)d;
+
+               if (year < 0) {
+                       return -1;
+               }
+
+               return year < 1900 ? 1900 + year : year;
+       }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Datedif.java b/src/java/org/apache/poi/hssf/record/formula/functions/Datedif.java
deleted file mode 100644 (file)
index 1a14516..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Datedif extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Datestring.java b/src/java/org/apache/poi/hssf/record/formula/functions/Datestring.java
deleted file mode 100644 (file)
index 0a80110..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Datestring extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Datevalue.java b/src/java/org/apache/poi/hssf/record/formula/functions/Datevalue.java
deleted file mode 100644 (file)
index a037752..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Datevalue extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Daverage.java b/src/java/org/apache/poi/hssf/record/formula/functions/Daverage.java
deleted file mode 100644 (file)
index ebf9c28..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Daverage extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Days360.java b/src/java/org/apache/poi/hssf/record/formula/functions/Days360.java
deleted file mode 100644 (file)
index 2187576..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Days360 extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Db.java b/src/java/org/apache/poi/hssf/record/formula/functions/Db.java
deleted file mode 100644 (file)
index 1dd80b6..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Db extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dbcs.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dbcs.java
deleted file mode 100644 (file)
index 30ad221..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dbcs extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dcount.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dcount.java
deleted file mode 100644 (file)
index 1d64ae2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dcount extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dcounta.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dcounta.java
deleted file mode 100644 (file)
index 72d36bc..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dcounta extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Ddb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Ddb.java
deleted file mode 100644 (file)
index 66b5a33..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Ddb extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Deref.java b/src/java/org/apache/poi/hssf/record/formula/functions/Deref.java
deleted file mode 100644 (file)
index bb77352..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Deref extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dget.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dget.java
deleted file mode 100644 (file)
index ebd8463..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dget extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dmax.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dmax.java
deleted file mode 100644 (file)
index 18ea2bd..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dmax extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dmin.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dmin.java
deleted file mode 100644 (file)
index 9307af5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dmin extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dproduct.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dproduct.java
deleted file mode 100644 (file)
index bf86748..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dproduct extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dstdev.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dstdev.java
deleted file mode 100644 (file)
index 0cdb4c2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dstdev extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dstdevp.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dstdevp.java
deleted file mode 100644 (file)
index e9a2bfa..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dstdevp extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dsum.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dsum.java
deleted file mode 100644 (file)
index 3c057ca..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dsum extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dvar.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dvar.java
deleted file mode 100644 (file)
index 764cf61..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dvar extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Dvarp.java b/src/java/org/apache/poi/hssf/record/formula/functions/Dvarp.java
deleted file mode 100644 (file)
index 03928b7..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Dvarp extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Echo.java b/src/java/org/apache/poi/hssf/record/formula/functions/Echo.java
deleted file mode 100644 (file)
index 87d4e29..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Echo extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Error.java b/src/java/org/apache/poi/hssf/record/formula/functions/Error.java
deleted file mode 100644 (file)
index 41a7ecd..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Error extends NotImplementedFunction {
-
-}
index abd32c94d075dceea0919e35ddda78a288e98fe7..0240f817e71d356f0c42a7d357ed4fc8c92639fa 100644 (file)
@@ -6,7 +6,7 @@
    (the "License"); you may not use this file except in compliance with
    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
    distributed under the License is distributed on an "AS IS" BASIS,
@@ -43,8 +43,8 @@ import org.apache.poi.hssf.usermodel.HSSFErrorConstants;
  *      <tr><td>#N/A!</td><td>7</td></tr>
  *      <tr><td>everything else</td><td>#N/A!</td></tr>
  *    </table>
- * 
- * Note - the results of ERROR.TYPE() are different to the constants defined in 
+ *
+ * Note - the results of ERROR.TYPE() are different to the constants defined in
  * <tt>HSSFErrorConstants</tt>.
  * </p>
  *
@@ -53,7 +53,7 @@ import org.apache.poi.hssf.usermodel.HSSFErrorConstants;
 public final class Errortype implements Function {
 
        public Eval evaluate(Eval[] args, int srcCellRow, short srcCellCol) {
-               
+
                try {
                        OperandResolver.getSingleValue(args[0], srcCellRow, srcCellCol);
                        return ErrorEval.NA;
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Evaluate.java b/src/java/org/apache/poi/hssf/record/formula/functions/Evaluate.java
deleted file mode 100644 (file)
index d458875..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Evaluate extends NotImplementedFunction {
-
-}
index eaeed89247b23e9e57cd0db1fcd00bcfda950a85..8426416d42d1e4c73160a55c139bef2b84492380 100644 (file)
@@ -20,7 +20,7 @@ package org.apache.poi.hssf.record.formula.functions;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- *  
+ *
  */
 public final class Even extends NumericFunction.OneArg {
 
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Exec.java b/src/java/org/apache/poi/hssf/record/formula/functions/Exec.java
deleted file mode 100644 (file)
index 327ba77..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Exec extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Expondist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Expondist.java
deleted file mode 100644 (file)
index 5ba8727..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Expondist extends NotImplementedFunction {
-
-}
index 2a16b1c73a47df0d6edb2bd5120b12154e5ba855..b94686bb9e9bcd9bd6719b1854ee0dd839df4d0b 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 6, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.BoolEval;
@@ -27,9 +24,9 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- *  
+ *
  */
-public class False implements Function {
+public final class False implements Function {
 
     public Eval evaluate(Eval[] operands, int srcRow, short srcCol) {
         ValueEval retval;
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Fdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Fdist.java
deleted file mode 100644 (file)
index be27363..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Fdist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Files.java b/src/java/org/apache/poi/hssf/record/formula/functions/Files.java
deleted file mode 100644 (file)
index 156fc67..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Files extends NotImplementedFunction {
-
-}
index 01fcf9ef0b1791c05b40bcaac0a101a92866d441..2de9ab13501e4043ec0dbef78b4766feab7a0f61 100644 (file)
@@ -34,7 +34,7 @@ public abstract class FinanceFunction extends NumericFunction.MultiArg {
                // All finance functions have 3 to 5 args, first 4 are numbers, last is boolean
                // default for last 2 args are 0.0 and false
                // Text boolean literals are not valid for the last arg
-               
+
                double arg3 = 0.0;
                double arg4 = 0.0;
 
index 96f8717a2c3b5ab10cf0ef2b1c23228b04cd3cc1..d811116c10018b4006c4b1a65b03a10e4df16425 100644 (file)
@@ -1,29 +1,26 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 21, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- * 
- * 
+ *
+ *
  * This class is a functon library for common fiscal functions.
  * <b>Glossary of terms/abbreviations:</b>
  * <br/>
@@ -32,9 +29,9 @@ package org.apache.poi.hssf.record.formula.functions;
  * <li><em>PV:</em> Present Value</li>
  * <li><em>NPV:</em> Net Present Value</li>
  * <li><em>PMT:</em> (Periodic) Payment</li>
- * 
+ *
  * </ul>
- * For more info on the terms/abbreviations please use the references below 
+ * For more info on the terms/abbreviations please use the references below
  * (hyperlinks are subject to change):
  * </br>Online References:
  * <ol>
@@ -59,19 +56,17 @@ package org.apache.poi.hssf.record.formula.functions;
  * ny + p + f=0                            ...{when r=0}
  * </pre>
  */
-public final class FinanceLib {
-    
-    // constants for default values
-    
-    
-    
-    private FinanceLib() {}
-    
+final class FinanceLib {
+
+    private FinanceLib() {
+        // no instances of this class
+    }
+
     /**
      * Future value of an amount given the number of payments, rate, amount
      * of individual payment, present value and boolean value indicating whether
-     * payments are due at the beginning of period 
-     * (false => payments are due at end of period) 
+     * payments are due at the beginning of period
+     * (false => payments are due at end of period)
      * @param r rate
      * @param n num of periods
      * @param y pmt per period
@@ -85,18 +80,18 @@ public final class FinanceLib {
         }
         else {
             double r1 = r + 1;
-            retval =((1-Math.pow(r1, n)) * (t ? r1 : 1) * y ) / r  
-                      - 
+            retval =((1-Math.pow(r1, n)) * (t ? r1 : 1) * y ) / r
+                      -
                    p*Math.pow(r1, n);
         }
         return retval;
     }
-    
+
     /**
      * Present value of an amount given the number of future payments, rate, amount
      * of individual payment, future value and boolean value indicating whether
-     * payments are due at the beginning of period 
-     * (false => payments are due at end of period) 
+     * payments are due at the beginning of period
+     * (false => payments are due at end of period)
      * @param r
      * @param n
      * @param y
@@ -116,12 +111,12 @@ public final class FinanceLib {
         }
         return retval;
     }
-    
+
     /**
      * calculates the Net Present Value of a principal amount
-     * given the discount rate and a sequence of cash flows 
-     * (supplied as an array). If the amounts are income the value should 
-     * be positive, else if they are payments and not income, the 
+     * given the discount rate and a sequence of cash flows
+     * (supplied as an array). If the amounts are income the value should
+     * be positive, else if they are payments and not income, the
      * value should be negative.
      * @param r
      * @param cfs cashflow amounts
@@ -136,9 +131,9 @@ public final class FinanceLib {
         }
         return npv;
     }
-    
+
     /**
-     * 
+     *
      * @param r
      * @param n
      * @param p
@@ -152,15 +147,15 @@ public final class FinanceLib {
         }
         else {
         double r1 = r + 1;
-        retval = ( f + p * Math.pow(r1, n) ) * r 
-                  / 
+        retval = ( f + p * Math.pow(r1, n) ) * r
+                  /
                ((t ? r1 : 1) * (1 - Math.pow(r1, n)));
         }
         return retval;
     }
 
     /**
-     * 
+     *
      * @param r
      * @param y
      * @param p
@@ -185,6 +180,6 @@ public final class FinanceLib {
         }
         return retval;
     }
-    
+
 
 }
index 5621eb5cea37ed3316047ec238ea16c44768ffb3..802b8161f535e83f2512ee8568cb4a7c817fde1a 100644 (file)
@@ -29,13 +29,13 @@ import org.apache.poi.hssf.record.formula.eval.EvaluationException;
  * <b>Syntax</b>:<br/>
  * <b>FIND</b>(<b>find_text</b>, <b>within_text</b>, start_num)<p/>
  *
- * FIND returns the character position of the first occurrence of <tt>find_text</tt> inside 
+ * FIND returns the character position of the first occurrence of <tt>find_text</tt> inside
  * <tt>within_text</tt>.  The third parameter, <tt>start_num</tt>, is optional (default=1)
  * and specifies where to start searching from.  Character positions are 1-based.<p/>
  *
  * @author Torstein Tauno Svendsen (torstei@officenet.no)
  */
-public class Find extends TextFunction {
+public final class Find extends TextFunction {
 
        protected ValueEval evaluateFunc(Eval[] args, int srcCellRow, short srcCellCol)
                        throws EvaluationException {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Findb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Findb.java
deleted file mode 100644 (file)
index e722f74..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Findb extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Finv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Finv.java
deleted file mode 100644 (file)
index 3ebb914..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Finv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Fisher.java b/src/java/org/apache/poi/hssf/record/formula/functions/Fisher.java
deleted file mode 100644 (file)
index 8d2fba2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Fisher extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Fisherinv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Fisherinv.java
deleted file mode 100644 (file)
index 9f5167c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Fisherinv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Fixed.java b/src/java/org/apache/poi/hssf/record/formula/functions/Fixed.java
deleted file mode 100644 (file)
index e5e5dc6..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Fixed extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Forecast.java b/src/java/org/apache/poi/hssf/record/formula/functions/Forecast.java
deleted file mode 100644 (file)
index 5fb4095..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Forecast extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Formulaconvert.java b/src/java/org/apache/poi/hssf/record/formula/functions/Formulaconvert.java
deleted file mode 100644 (file)
index 32b3a7b..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Formulaconvert extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Fpos.java b/src/java/org/apache/poi/hssf/record/formula/functions/Fpos.java
deleted file mode 100644 (file)
index 6e0b66f..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Fpos extends NotImplementedFunction {
-
-}
index cdec045b40e2da35c9396efb251d7471bc34a78c..edec7df5ceeb239132a564d7acdde8de728e1c3d 100755 (executable)
@@ -23,34 +23,34 @@ import org.apache.poi.ss.formula.EvaluationWorkbook;
 
 
 /**
- * For most Excel functions, involving references ((cell, area), (2d, 3d)), the references are 
+ * For most Excel functions, involving references ((cell, area), (2d, 3d)), the references are
  * passed in as arguments, and the exact location remains fixed.  However, a select few Excel
  * functions have the ability to access cells that were not part of any reference passed as an
  * argument.<br/>
  * Two important functions with this feature are <b>INDIRECT</b> and <b>OFFSET</b><p/>
- *  
+ *
  * In POI, the <tt>HSSFFormulaEvaluator</tt> evaluates every cell in each reference argument before
  * calling the function.  This means that functions using fixed references do not need access to
  * the rest of the workbook to execute.  Hence the <tt>evaluate()</tt> method on the common
- * interface <tt>Function</tt> does not take a workbook parameter.<p>  
- * 
- * This interface recognises the requirement of some functions to freely create and evaluate 
+ * interface <tt>Function</tt> does not take a workbook parameter.<p>
+ *
+ * This interface recognises the requirement of some functions to freely create and evaluate
  * references beyond those passed in as arguments.
- * 
+ *
  * @author Josh Micich
  */
 public interface FreeRefFunction {
        /**
-        * 
+        *
         * @param args the pre-evaluated arguments for this function. args is never <code>null</code>,
         *                nor are any of its elements.
         * @param srcCellSheet zero based sheet index of the cell containing the currently evaluating formula
-        * @param srcCellRow zero based row index of the cell containing the currently evaluating formula 
-        * @param srcCellCol zero based column index of the cell containing the currently evaluating formula 
+        * @param srcCellRow zero based row index of the cell containing the currently evaluating formula
+        * @param srcCellCol zero based column index of the cell containing the currently evaluating formula
         * @param workbook is the workbook containing the formula/cell being evaluated
-        * @return never <code>null</code>. Possibly an instance of <tt>ErrorEval</tt> in the case of 
+        * @return never <code>null</code>. Possibly an instance of <tt>ErrorEval</tt> in the case of
         * a specified Excel error (Exceptions are never thrown to represent Excel errors).
-        * 
+        *
         */
        ValueEval evaluate(Eval[] args, EvaluationWorkbook workbook, int srcCellSheet, int srcCellRow, int srcCellCol);
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Frequency.java b/src/java/org/apache/poi/hssf/record/formula/functions/Frequency.java
deleted file mode 100644 (file)
index fc003c3..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Frequency extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Ftest.java b/src/java/org/apache/poi/hssf/record/formula/functions/Ftest.java
deleted file mode 100644 (file)
index fb66202..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Ftest extends NotImplementedFunction {
-
-}
index 3bce8ffa83ed3ac6219f992603b67f4e76491306..90e6afe05fa107cc8db366f88c90cdd00b0d50da 100644 (file)
@@ -25,22 +25,22 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * Common interface for all implementations of Excel built-in functions.
- * 
+ *
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  */
 public interface Function {
 
        /**
-        * @param args the evaluated function arguments. Elements of this array typically implement 
-        * {@link ValueEval}.  Empty values are represented with {@link BlankEval} or {@link 
+        * @param args the evaluated function arguments. Elements of this array typically implement
+        * {@link ValueEval}.  Empty values are represented with {@link BlankEval} or {@link
         * MissingArgEval}, never <code>null</code>.
         * @param srcRowIndex row index of the cell containing the formula under evaluation
         * @param srcColumnIndex column index of the cell containing the formula under evaluation
         * @return The evaluated result, possibly an {@link ErrorEval}, never <code>null</code>.
         * <b>Note</b> - Excel uses the error code <i>#NUM!</i> instead of IEEE <i>NaN</i>, so when
-        * numeric functions evaluate to {@link Double#NaN} be sure to translate the result to {@link 
-        * ErrorEval#NUM_ERROR}. 
-        * 
+        * numeric functions evaluate to {@link Double#NaN} be sure to translate the result to {@link
+        * ErrorEval#NUM_ERROR}.
+        *
         */
        Eval evaluate(Eval[] args, int srcRowIndex, short srcColumnIndex);
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Gammadist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Gammadist.java
deleted file mode 100644 (file)
index fa788c5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Gammadist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Gammainv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Gammainv.java
deleted file mode 100644 (file)
index ea8bdc5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Gammainv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Gammaln.java b/src/java/org/apache/poi/hssf/record/formula/functions/Gammaln.java
deleted file mode 100644 (file)
index fb60266..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Gammaln extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Geomean.java b/src/java/org/apache/poi/hssf/record/formula/functions/Geomean.java
deleted file mode 100644 (file)
index 1669a78..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Geomean extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Goto.java b/src/java/org/apache/poi/hssf/record/formula/functions/Goto.java
deleted file mode 100644 (file)
index c1a4d59..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Goto extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Group.java b/src/java/org/apache/poi/hssf/record/formula/functions/Group.java
deleted file mode 100644 (file)
index 91c6cc5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Group extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Growth.java b/src/java/org/apache/poi/hssf/record/formula/functions/Growth.java
deleted file mode 100644 (file)
index 5a35a2b..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Growth extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Halt.java b/src/java/org/apache/poi/hssf/record/formula/functions/Halt.java
deleted file mode 100644 (file)
index 74ce576..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Halt extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Harmean.java b/src/java/org/apache/poi/hssf/record/formula/functions/Harmean.java
deleted file mode 100644 (file)
index ade3109..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Harmean extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Help.java b/src/java/org/apache/poi/hssf/record/formula/functions/Help.java
deleted file mode 100644 (file)
index 1bf4004..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Help extends NotImplementedFunction {
-
-}
index 2bbf6f5cd571bbf9d04c12c259886d656ad1a30e..8230fb01f9a4010cf0cf2d7f0a3fdcbb770a4536 100644 (file)
@@ -26,22 +26,22 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 import org.apache.poi.hssf.record.formula.functions.LookupUtils.ValueVector;
 /**
  * Implementation of the HLOOKUP() function.<p/>
- * 
+ *
  * HLOOKUP finds a column in a lookup table by the first row value and returns the value from another row.<br/>
- * 
+ *
  * <b>Syntax</b>:<br/>
  * <b>HLOOKUP</b>(<b>lookup_value</b>, <b>table_array</b>, <b>row_index_num</b>, range_lookup)<p/>
- * 
+ *
  * <b>lookup_value</b>  The value to be found in the first column of the table array.<br/>
  * <b>table_array</b> An area reference for the lookup data. <br/>
  * <b>row_index_num</b> a 1 based index specifying which row value of the lookup data will be returned.<br/>
- * <b>range_lookup</b> If TRUE (default), HLOOKUP finds the largest value less than or equal to 
- * the lookup_value.  If FALSE, only exact matches will be considered<br/>   
- * 
+ * <b>range_lookup</b> If TRUE (default), HLOOKUP finds the largest value less than or equal to
+ * the lookup_value.  If FALSE, only exact matches will be considered<br/>
+ *
  * @author Josh Micich
  */
 public final class Hlookup implements Function {
-       
+
        public Eval evaluate(Eval[] args, int srcCellRow, short srcCellCol) {
                Eval arg3 = null;
                switch(args.length) {
@@ -71,9 +71,9 @@ public final class Hlookup implements Function {
 
        /**
         * Returns one column from an <tt>AreaEval</tt>
-        * 
+        *
         * @param rowIndex assumed to be non-negative
-        * 
+        *
         * @throws EvaluationException (#REF!) if colIndex is too high
         */
        private ValueVector createResultColumnVector(AreaEval tableArray, int rowIndex) throws EvaluationException {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Hour.java b/src/java/org/apache/poi/hssf/record/formula/functions/Hour.java
deleted file mode 100644 (file)
index 0caeda4..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Hour extends NotImplementedFunction {
-
-}
index d729762a5027a7756b534f3dcb58618a062a2fe3..ecfdebf26f80808d382ef2163903fbf706398b79 100644 (file)
@@ -25,21 +25,21 @@ import org.apache.poi.hssf.record.formula.eval.StringEval;
 
 /**
  * Implementation of Excel HYPERLINK function.<p/>
- * 
+ *
  * In Excel this function has special behaviour - it causes the displayed cell value to behave like
- * a hyperlink in the GUI. From an evaluation perspective however, it is very simple.<p/> 
- * 
+ * a hyperlink in the GUI. From an evaluation perspective however, it is very simple.<p/>
+ *
  * <b>Syntax</b>:<br/>
  * <b>HYPERLINK</b>(<b>link_location</b>, friendly_name)<p/>
- * 
+ *
  * <b>link_location</b> The URL of the hyperlink <br/>
  * <b>friendly_name</b> (optional) the value to display<p/>
- * 
+ *
  *  Returns last argument.  Leaves type unchanged (does not convert to {@link StringEval}).
 
  * @author Wayne Clingingsmith
  */
-public class Hyperlink implements Function {
+public final class Hyperlink implements Function {
 
        public Eval evaluate(Eval[] operands, int srcRow, short srcCol) {
                int lastArgIx = operands.length - 1;
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Hypgeomdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Hypgeomdist.java
deleted file mode 100644 (file)
index 9c76cc1..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Hypgeomdist extends NotImplementedFunction {
-
-}
index 4b066b8226ae88031a16c22e8f19433ad998d66d..450a96834b048aa4aa87b2a2b55f046612241466 100644 (file)
@@ -26,7 +26,7 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- * 
+ *
  */
 public final class If implements Function {
 
index 371a06e30ad7824244b77d5b8f2a7ec4e41dbef1..b4eca2b9b5dd4ec2b1857f409219301f9dc378a0 100644 (file)
@@ -62,7 +62,6 @@ public final class Index implements Function {
 
                        // else the other variation of this function takes an array as the first argument
                        // it seems like interface 'ArrayEval' does not even exist yet
-
                        throw new RuntimeException("Incomplete code - cannot handle first arg of type ("
                                        + firstArg.getClass().getName() + ")");
                }
index acac8488d42436bf84e230153135fab8d6da6f81..4640a099a25063d53b70d96f681c2022c4e2d79d 100644 (file)
@@ -24,18 +24,18 @@ import org.apache.poi.ss.formula.eval.NotImplementedException;
 
 /**
  * Implementation for Excel function INDIRECT<p/>
- * 
- * INDIRECT() returns the cell or area reference denoted by the text argument.<p/> 
- * 
+ *
+ * INDIRECT() returns the cell or area reference denoted by the text argument.<p/>
+ *
  * <b>Syntax</b>:</br>
  * <b>INDIRECT</b>(<b>ref_text</b>,isA1Style)<p/>
- * 
+ *
  * <b>ref_text</b> a string representation of the desired reference as it would normally be written
  * in a cell formula.<br/>
  * <b>isA1Style</b> (default TRUE) specifies whether the ref_text should be interpreted as A1-style
  * or R1C1-style.
- * 
- * 
+ *
+ *
  * @author Josh Micich
  */
 public final class Indirect implements FreeRefFunction {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Info.java b/src/java/org/apache/poi/hssf/record/formula/functions/Info.java
deleted file mode 100644 (file)
index 2b542dd..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Info extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Initiate.java b/src/java/org/apache/poi/hssf/record/formula/functions/Initiate.java
deleted file mode 100644 (file)
index 6795c7a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Initiate extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Input.java b/src/java/org/apache/poi/hssf/record/formula/functions/Input.java
deleted file mode 100644 (file)
index 0d3614c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Input extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Intercept.java b/src/java/org/apache/poi/hssf/record/formula/functions/Intercept.java
deleted file mode 100644 (file)
index bf94b5b..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Intercept extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Ipmt.java b/src/java/org/apache/poi/hssf/record/formula/functions/Ipmt.java
deleted file mode 100644 (file)
index 61e85a4..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Ipmt extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Irr.java b/src/java/org/apache/poi/hssf/record/formula/functions/Irr.java
deleted file mode 100644 (file)
index f23325e..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Irr extends NotImplementedFunction {
-
-}
index 786060704e3aafa2da981d25031568c8a5edc5fa..818a463d955159869798b324f4d52b779f191b75 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.AreaEval;
@@ -31,12 +28,12 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  *
  */
-public class IsError implements Function {
+public final class IsError implements Function {
 
     public Eval evaluate(Eval[] operands, int srcCellRow, short srcCellCol) {
         ValueEval retval = null;
         boolean b = false;
-        
+
         switch (operands.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -53,9 +50,9 @@ public class IsError implements Function {
                 else if (ae.isRow()) {
                     if (ae.containsColumn(srcCellCol)) {
                         ValueEval ve = ae.getValueAt(ae.getFirstRow(), srcCellCol);
-                        if (ve instanceof RefEval) 
+                        if (ve instanceof RefEval)
                             b = ((RefEval) ve).getInnerValueEval() instanceof ErrorEval;
-                        else 
+                        else
                             b = (ve instanceof ErrorEval);
                     }
                     else {
@@ -65,9 +62,9 @@ public class IsError implements Function {
                 else if (ae.isColumn()) {
                     if (ae.containsRow(srcCellRow)) {
                         ValueEval ve = ae.getValueAt(srcCellRow, ae.getFirstColumn());
-                        if (ve instanceof RefEval) 
+                        if (ve instanceof RefEval)
                             b = ((RefEval) ve).getInnerValueEval() instanceof ErrorEval;
-                        else 
+                        else
                             b = (ve instanceof ErrorEval);
                     }
                     else {
@@ -85,7 +82,7 @@ public class IsError implements Function {
                 b = false;
             }
         }
-        
+
         if (retval == null) {
             retval = b
                     ? BoolEval.TRUE
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/IsNa.java b/src/java/org/apache/poi/hssf/record/formula/functions/IsNa.java
deleted file mode 100644 (file)
index b1f8f09..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class IsNa extends NotImplementedFunction {
-
-}
index c0e482e5a8e70de1688531003318449a88129597..655d296c396ee813a07f00ec7f90b656f23c256f 100644 (file)
@@ -1,19 +1,19 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
 
 package org.apache.poi.hssf.record.formula.functions;
 
@@ -36,7 +36,7 @@ public final class Isblank implements Function {
                        return ErrorEval.VALUE_INVALID;
                }
                Eval arg = args[0];
-               
+
                ValueEval singleCellValue;
                try {
                        singleCellValue = OperandResolver.getSingleValue(arg, srcCellRow, srcCellCol);
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Iserr.java b/src/java/org/apache/poi/hssf/record/formula/functions/Iserr.java
deleted file mode 100644 (file)
index f1ebd48..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Iserr extends NotImplementedFunction {
-
-}
index 318d1e69f1754e008b9fe6c6180e02b93ae90a03..666c89ee048013a38b96bbf5dfb9a3ab600a0441 100644 (file)
@@ -1,40 +1,36 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 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.Eval;
 import org.apache.poi.hssf.record.formula.eval.RefEval;
-import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  *
  */
-public class Islogical extends LogicalFunction {
+public final class Islogical extends LogicalFunction {
 
     public Eval evaluate(Eval[] operands, int srcCellRow, short srcCellCol) {
         Eval retval = BoolEval.FALSE;
-        
+
         switch (operands.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -51,7 +47,7 @@ public class Islogical extends LogicalFunction {
                 }
             }
         }
-        
+
         return retval;
     }
 }
index eb07e63eb845b91bc201e953bb2cf3486b9c705d..e62dc690192f1eca9c3744dee45843d4d1bbcefb 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.BoolEval;
@@ -30,10 +27,10 @@ import org.apache.poi.hssf.record.formula.eval.StringEval;
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  *
  */
-public class Isnontext extends LogicalFunction {
+public final class Isnontext extends LogicalFunction {
     public Eval evaluate(Eval[] operands, int srcCellRow, short srcCellCol) {
         Eval retval = BoolEval.TRUE;
-        
+
         switch (operands.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -50,7 +47,7 @@ public class Isnontext extends LogicalFunction {
                 }
             }
         }
-        
+
         return retval;
     }
 }
index e3ff8d49aa141afe960612bfbbb0840123dbd47c..f00fd05c240575fa73290c63db7faa92d376fa4f 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.BoolEval;
@@ -30,10 +27,10 @@ import org.apache.poi.hssf.record.formula.eval.RefEval;
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  *
  */
-public class Isnumber extends LogicalFunction {
+public final class Isnumber extends LogicalFunction {
     public Eval evaluate(Eval[] operands, int srcCellRow, short srcCellCol) {
         Eval retval = BoolEval.FALSE;
-        
+
         switch (operands.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -50,7 +47,7 @@ public class Isnumber extends LogicalFunction {
                 }
             }
         }
-        
+
         return retval;
     }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Ispmt.java b/src/java/org/apache/poi/hssf/record/formula/functions/Ispmt.java
deleted file mode 100644 (file)
index 69c7f42..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Ispmt extends NotImplementedFunction {
-
-}
index 1deb606544327a6b353ad10b3c8f0b0508a3ecf7..565d5e49896d5abdbeaed584281c3936de6fbbf0 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.AreaEval;
@@ -30,10 +27,10 @@ import org.apache.poi.hssf.record.formula.eval.RefEval;
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  *
  */
-public class Isref implements Function {
+public final class Isref implements Function {
     public Eval evaluate(Eval[] operands, int srcCellRow, short srcCellCol) {
         Eval retval = BoolEval.FALSE;
-        
+
         switch (operands.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -44,7 +41,7 @@ public class Isref implements Function {
                 retval = BoolEval.TRUE;
             }
         }
-        
+
         return retval;
     }
 }
index ec87d79cbd17fcf5479738d99e99d3507cc8673c..f669d7f4973e9250f2ccba30451f983438ab77f3 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.BoolEval;
@@ -30,10 +27,10 @@ import org.apache.poi.hssf.record.formula.eval.StringEval;
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  *
  */
-public class Istext extends LogicalFunction {
+public final class Istext extends LogicalFunction {
     public Eval evaluate(Eval[] operands, int srcCellRow, short srcCellCol) {
         Eval retval = BoolEval.FALSE;
-        
+
         switch (operands.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -50,7 +47,7 @@ public class Istext extends LogicalFunction {
                 }
             }
         }
-        
+
         return retval;
     }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Kurt.java b/src/java/org/apache/poi/hssf/record/formula/functions/Kurt.java
deleted file mode 100644 (file)
index fe4e76e..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Kurt extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Lasterror.java b/src/java/org/apache/poi/hssf/record/formula/functions/Lasterror.java
deleted file mode 100644 (file)
index c5024a5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Lasterror extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Leftb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Leftb.java
deleted file mode 100644 (file)
index 9c3d362..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Leftb extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Lenb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Lenb.java
deleted file mode 100644 (file)
index b47105a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Lenb extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Linest.java b/src/java/org/apache/poi/hssf/record/formula/functions/Linest.java
deleted file mode 100644 (file)
index ea415a4..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Linest extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Links.java b/src/java/org/apache/poi/hssf/record/formula/functions/Links.java
deleted file mode 100644 (file)
index 1f2d570..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Links extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Logest.java b/src/java/org/apache/poi/hssf/record/formula/functions/Logest.java
deleted file mode 100644 (file)
index 2a36f7d..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Logest extends NotImplementedFunction {
-
-}
index 03756e1faf74137d4340a15f84d64c385a4a4a29..ae5a0ebf6b1d4635116fc4c5df88eefde6f9a17b 100644 (file)
@@ -1,25 +1,23 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on Nov 25, 2006
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
+import org.apache.poi.hssf.record.formula.eval.OperandResolver;
 import org.apache.poi.hssf.record.formula.eval.RefEval;
 import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
@@ -31,11 +29,11 @@ public abstract class LogicalFunction implements Function {
 
     /**
      * recursively evaluate any RefEvals
-     * @param reval
+     * TODO - use {@link OperandResolver}
      */
     protected ValueEval xlateRefEval(RefEval reval) {
-        ValueEval retval = (ValueEval) reval.getInnerValueEval();
-        
+        ValueEval retval = reval.getInnerValueEval();
+
         if (retval instanceof RefEval) {
             RefEval re = (RefEval) retval;
             retval = xlateRefEval(re);
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Loginv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Loginv.java
deleted file mode 100644 (file)
index 8b885ca..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Loginv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Lognormdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Lognormdist.java
deleted file mode 100644 (file)
index 26ca53b..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Lognormdist extends NotImplementedFunction {
-
-}
index 305d8fb0d7dbb645305c404d1d62732095821add..0cbae7fb8824f2cfb7c87bad5ae0a2f3caf8e710 100644 (file)
@@ -27,16 +27,16 @@ import org.apache.poi.hssf.record.formula.functions.LookupUtils.ValueVector;
 
 /**
  * Implementation of Excel function LOOKUP.<p/>
- * 
+ *
  * LOOKUP finds an index  row in a lookup table by the first column value and returns the value from another column.
- * 
+ *
  * <b>Syntax</b>:<br/>
  * <b>VLOOKUP</b>(<b>lookup_value</b>, <b>lookup_vector</b>, result_vector)<p/>
- * 
+ *
  * <b>lookup_value</b>  The value to be found in the lookup vector.<br/>
  * <b>lookup_vector</> An area reference for the lookup data. <br/>
  * <b>result_vector</b> Single row or single column area reference from which the result value is chosen.<br/>
- * 
+ *
  * @author Josh Micich
  */
 public final class Lookup implements Function {
@@ -51,13 +51,13 @@ public final class Lookup implements Function {
                        default:
                                return ErrorEval.VALUE_INVALID;
                }
-               
-               
+
+
                try {
                        ValueEval lookupValue = OperandResolver.getSingleValue(args[0], srcCellRow, srcCellCol);
                        AreaEval aeLookupVector = LookupUtils.resolveTableArrayArg(args[1]);
                        AreaEval aeResultVector = LookupUtils.resolveTableArrayArg(args[2]);
-                       
+
                        ValueVector lookupVector = createVector(aeLookupVector);
                        ValueVector resultVector = createVector(aeResultVector);
                        if(lookupVector.getSize() > resultVector.getSize()) {
@@ -65,7 +65,7 @@ public final class Lookup implements Function {
                                throw new RuntimeException("Lookup vector and result vector of differing sizes not supported yet");
                        }
                        int index = LookupUtils.lookupIndexOfValue(lookupValue, lookupVector, true);
-                       
+
                        return resultVector.getItem(index);
                } catch (EvaluationException e) {
                        return e.getErrorEval();
index 613a3d144cb8cdb843ad2129213b9e05119a4748..376d9a4e0afba9fd52a24a4192a1951c0cf1acb0 100644 (file)
@@ -218,7 +218,7 @@ final class LookupUtils {
 
        private static abstract class LookupValueComparerBase implements LookupValueComparer {
 
-               private final Class _targetClass;
+               private final Class<? extends ValueEval> _targetClass;
                protected LookupValueComparerBase(ValueEval targetValue) {
                        if(targetValue == null) {
                                throw new RuntimeException("targetValue cannot be null");
@@ -231,9 +231,6 @@ final class LookupUtils {
                        }
                        if (_targetClass != other.getClass()) {
                                return CompareResult.TYPE_MISMATCH;
-                       }
-                       if (_targetClass == StringEval.class) {
-
                        }
                        return compareSameType(other);
                }
@@ -330,7 +327,7 @@ final class LookupUtils {
                if(rowColIndexArg == null) {
                        throw new IllegalArgumentException("argument must not be null");
                }
-               
+
                ValueEval veRowColIndexArg;
                try {
                        veRowColIndexArg = OperandResolver.getSingleValue(rowColIndexArg, srcCellRow, (short)srcCellCol);
@@ -353,7 +350,7 @@ final class LookupUtils {
                // actual BoolEval values get interpreted as FALSE->0 and TRUE->1
                oneBasedIndex = OperandResolver.coerceValueToInt(veRowColIndexArg);
                if (oneBasedIndex < 1) {
-                       // note this is asymmetric with the errors when the index is too large (#REF!)  
+                       // note this is asymmetric with the errors when the index is too large (#REF!)
                        throw EvaluationException.invalidValue();
                }
                return oneBasedIndex - 1; // convert to zero based
@@ -599,7 +596,7 @@ final class LookupUtils {
                if (lookupValue == BlankEval.INSTANCE) {
                        // blank eval translates to zero
                        // Note - a blank eval in the lookup column/row never matches anything
-                       // empty string in the lookup column/row can only be matched by explicit emtpty string
+                       // empty string in the lookup column/row can only be matched by explicit empty string
                        return new NumberLookupComparer(NumberEval.ZERO);
                }
                if (lookupValue instanceof StringEval) {
index a464ec873aeb90ba949c08c1dcc377b92fdb3b2f..7a8cc6cc24a6c6ae34a4b1432403c2d123d40456 100644 (file)
@@ -1,19 +1,19 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
 
 package org.apache.poi.hssf.record.formula.functions;
 
@@ -229,7 +229,7 @@ public final class Match implements Function {
                throw new EvaluationException(ErrorEval.NA);
        }
 
-       private static LookupValueComparer createLookupComparer(ValueEval lookupValue, boolean matchExact) throws EvaluationException {
+       private static LookupValueComparer createLookupComparer(ValueEval lookupValue, boolean matchExact) {
                if (matchExact && lookupValue instanceof StringEval) {
                        String stringValue = ((StringEval) lookupValue).getStringValue();
                        if(isLookupValueWild(stringValue)) {
index 311707665ea7e07e433426bde3e21bb733352ada..f51821d0423fdb1d0f49dc76afaf99177534532e 100644 (file)
@@ -1,26 +1,21 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 19, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
 
+       http://www.apache.org/licenses/LICENSE-2.0
 
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
+package org.apache.poi.hssf.record.formula.functions;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
@@ -28,22 +23,23 @@ package org.apache.poi.hssf.record.formula.functions;
  * provided by java.lang.Math class. It follows the Math class
  * in that it has a private constructor and all static methods.
  */
-public final class MathX {
+final class MathX {
+
+    private MathX() {
+        // no instances of this class
+    }
+
 
-    
-    private MathX() {}
-    
-    
     /**
      * Returns a value rounded to p digits after decimal.
      * If p is negative, then the number is rounded to
-     * places to the left of the decimal point. eg. 
+     * places to the left of the decimal point. eg.
      * 10.23 rounded to -1 will give: 10. If p is zero,
      * the returned value is rounded to the nearest integral
      * value.
      * <p>If n is negative, the resulting value is obtained
      * as the round value of absolute value of n multiplied
-     * by the sign value of n (@see MathX.sign(double d)). 
+     * by the sign value of n (@see MathX.sign(double d)).
      * Thus, -0.6666666 rounded to p=0 will give -1 not 0.
      * <p>If n is NaN, returned value is NaN.
      * @param n
@@ -51,7 +47,7 @@ public final class MathX {
      */
     public static double round(double n, int p) {
         double retval;
-        
+
         if (Double.isNaN(n) || Double.isInfinite(n)) {
             retval = Double.NaN;
         }
@@ -64,20 +60,20 @@ public final class MathX {
                 retval = Math.round(n);
             }
         }
-        
+
         return retval;
     }
 
     /**
      * Returns a value rounded-up to p digits after decimal.
      * If p is negative, then the number is rounded to
-     * places to the left of the decimal point. eg. 
+     * places to the left of the decimal point. eg.
      * 10.23 rounded to -1 will give: 20. If p is zero,
      * the returned value is rounded to the nearest integral
      * value.
      * <p>If n is negative, the resulting value is obtained
      * as the round-up value of absolute value of n multiplied
-     * by the sign value of n (@see MathX.sign(double d)). 
+     * by the sign value of n (@see MathX.sign(double d)).
      * Thus, -0.2 rounded-up to p=0 will give -1 not 0.
      * <p>If n is NaN, returned value is NaN.
      * @param n
@@ -85,7 +81,7 @@ public final class MathX {
      */
     public static double roundUp(double n, int p) {
         double retval;
-        
+
         if (Double.isNaN(n) || Double.isInfinite(n)) {
             retval = Double.NaN;
         }
@@ -93,34 +89,34 @@ public final class MathX {
             if (p != 0) {
                 double temp = Math.pow(10, p);
                 double nat = Math.abs(n*temp);
-                
-                retval = sign(n) * 
+
+                retval = sign(n) *
                     ((nat == (long) nat)
                             ? nat / temp
                             : Math.round(nat + 0.5) / temp);
             }
             else {
                 double na = Math.abs(n);
-                retval = sign(n) * 
+                retval = sign(n) *
                     ((na == (long) na)
                         ? na
                         : (long) na + 1);
             }
         }
-        
+
         return retval;
     }
 
     /**
      * Returns a value rounded to p digits after decimal.
      * If p is negative, then the number is rounded to
-     * places to the left of the decimal point. eg. 
+     * places to the left of the decimal point. eg.
      * 10.23 rounded to -1 will give: 10. If p is zero,
      * the returned value is rounded to the nearest integral
      * value.
      * <p>If n is negative, the resulting value is obtained
      * as the round-up value of absolute value of n multiplied
-     * by the sign value of n (@see MathX.sign(double d)). 
+     * by the sign value of n (@see MathX.sign(double d)).
      * Thus, -0.8 rounded-down to p=0 will give 0 not -1.
      * <p>If n is NaN, returned value is NaN.
      * @param n
@@ -128,7 +124,7 @@ public final class MathX {
      */
     public static double roundDown(double n, int p) {
         double retval;
-        
+
         if (Double.isNaN(n) || Double.isInfinite(n)) {
             retval = Double.NaN;
         }
@@ -141,17 +137,17 @@ public final class MathX {
                 retval = (long) n;
             }
         }
-        
+
         return retval;
     }
-    
-    
+
+
     /**
      * If d < 0, returns short -1
      * <br/>
      * If d > 0, returns short 1
      * <br/>
-     * If d == 0, returns short 0 
+     * If d == 0, returns short 0
      * <p> If d is NaN, then 1 will be returned. It is the responsibility
      * of caller to check for d isNaN if some other value is desired.
      * @param d
@@ -163,7 +159,7 @@ public final class MathX {
                         ? -1
                         : 1);
     }
-   
+
     /**
      * average of all values
      * @param values
@@ -177,8 +173,8 @@ public final class MathX {
         ave = sum / values.length;
         return ave;
     }
-    
-    
+
+
     /**
      * sum of all values
      * @param values
@@ -190,7 +186,7 @@ public final class MathX {
         }
         return sum;
     }
-    
+
     /**
      * sum of squares of all values
      * @param values
@@ -202,8 +198,8 @@ public final class MathX {
         }
         return sumsq;
     }
-    
-    
+
+
     /**
      * product of all values
      * @param values
@@ -218,7 +214,7 @@ public final class MathX {
         }
         return product;
     }
-    
+
     /**
      * min of all values. If supplied array is zero length,
      * Double.POSITIVE_INFINITY is returned.
@@ -262,17 +258,17 @@ public final class MathX {
      */
     public static double floor(double n, double s) {
         double f;
-        
+
         if ((n<0 && s>0) || (n>0 && s<0) || (s==0 && n!=0)) {
             f = Double.NaN;
         }
         else {
             f = (n==0 || s==0) ? 0 : Math.floor(n/s) * s;
         }
-        
+
         return f;
     }
-    
+
     /**
      * Note: this function is different from java.lang.Math.ceil(..).
      * <p>
@@ -290,30 +286,30 @@ public final class MathX {
      */
     public static double ceiling(double n, double s) {
         double c;
-        
+
         if ((n<0 && s>0) || (n>0 && s<0)) {
             c = Double.NaN;
         }
         else {
             c = (n == 0 || s == 0) ? 0 : Math.ceil(n/s) * s;
         }
-        
+
         return c;
     }
-    
+
     /**
-     * <br/> for all n >= 1; factorial n = n * (n-1) * (n-2) * ... * 1 
+     * <br/> for all n >= 1; factorial n = n * (n-1) * (n-2) * ... * 1
      * <br/> else if n == 0; factorial n = 1
      * <br/> else if n < 0; factorial n = Double.NaN
      * <br/> Loss of precision can occur if n is large enough.
-     * If n is large so that the resulting value would be greater 
+     * If n is large so that the resulting value would be greater
      * than Double.MAX_VALUE; Double.POSITIVE_INFINITY is returned.
-     * If n < 0, Double.NaN is returned. 
+     * If n < 0, Double.NaN is returned.
      * @param n
      */
     public static double factorial(int n) {
         double d = 1;
-        
+
         if (n >= 0) {
             if (n <= 170) {
                 for (int i=1; i<=n; i++) {
@@ -329,11 +325,11 @@ public final class MathX {
         }
         return d;
     }
-    
+
 
     /**
      * returns the remainder resulting from operation:
-     * n / d. 
+     * n / d.
      * <br/> The result has the sign of the divisor.
      * <br/> Examples:
      * <ul>
@@ -348,7 +344,7 @@ public final class MathX {
      */
     public static double mod(double n, double d) {
         double result = 0;
-        
+
         if (d == 0) {
             result = Double.NaN;
         }
@@ -363,11 +359,11 @@ public final class MathX {
             t = Math.ceil(t) - t;
             result = sign(d) * Math.abs(t * d);
         }
-        
+
         return result;
     }
-    
-    
+
+
     /**
      * inverse hyperbolic cosine
      * @param d
@@ -375,16 +371,15 @@ public final class MathX {
     public static double acosh(double d) {
         return Math.log(Math.sqrt(Math.pow(d, 2) - 1) + d);
     }
-    
+
     /**
      * inverse hyperbolic sine
      * @param d
      */
     public static double asinh(double d) {
-        double d2 = d*d;
         return Math.log(Math.sqrt(d*d + 1) + d);
     }
-    
+
     /**
      * inverse hyperbolic tangent
      * @param d
@@ -392,7 +387,7 @@ public final class MathX {
     public static double atanh(double d) {
         return Math.log((1 + d)/(1 - d)) / 2;
     }
-    
+
     /**
      * hyperbolic cosine
      * @param d
@@ -400,10 +395,9 @@ public final class MathX {
     public static double cosh(double d) {
         double ePowX = Math.pow(Math.E, d);
         double ePowNegX = Math.pow(Math.E, -d);
-        d = (ePowX + ePowNegX) / 2;
-        return d;
+        return (ePowX + ePowNegX) / 2;
     }
-    
+
     /**
      * hyperbolic sine
      * @param d
@@ -411,10 +405,9 @@ public final class MathX {
     public static double sinh(double d) {
         double ePowX = Math.pow(Math.E, d);
         double ePowNegX = Math.pow(Math.E, -d);
-        d = (ePowX - ePowNegX) / 2;
-        return d;
+        return (ePowX - ePowNegX) / 2;
     }
-    
+
     /**
      * hyperbolic tangent
      * @param d
@@ -422,40 +415,10 @@ public final class MathX {
     public static double tanh(double d) {
         double ePowX = Math.pow(Math.E, d);
         double ePowNegX = Math.pow(Math.E, -d);
-        d = (ePowX - ePowNegX) / (ePowX + ePowNegX);
-        return d;
+        return (ePowX - ePowNegX) / (ePowX + ePowNegX);
     }
-    
-    /**
-     * returns the sum of product of corresponding double value in each
-     * subarray. It is the responsibility of the caller to ensure that
-     * all the subarrays are of equal length. If the subarrays are
-     * not of equal length, the return value can be unpredictable.
-     * @param arrays
-     */
-    public static double sumproduct(double[][] arrays) {
-        double d = 0;
-        
-        try {
-            int narr = arrays.length;
-            int arrlen = arrays[0].length; 
-            
-            for (int j=0; j<arrlen; j++) {
-                double t = 1;
-                for (int i=0; i<narr; i++) {
-                    t *= arrays[i][j];
-                }
-                d += t;
-            }            
-        }
-        catch (ArrayIndexOutOfBoundsException ae) {
-            d = Double.NaN;
-        }
-        
-        return d;
-    }
-    
-    
+
+
     /**
      * returns the total number of combinations possible when
      * k items are chosen out of total of n items. If the number
@@ -479,8 +442,8 @@ public final class MathX {
             }
             d /= factorial(minnk);
         }
-        
+
         return d;
     }
-    
+
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Mdeterm.java b/src/java/org/apache/poi/hssf/record/formula/functions/Mdeterm.java
deleted file mode 100644 (file)
index ab57658..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Mdeterm extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Midb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Midb.java
deleted file mode 100644 (file)
index 2a06e4e..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Midb extends NotImplementedFunction {
-
-}
index 70e5e7ff1b141afc034ec8900e642332634e279e..cc0d35e14a6afe1dee3194733878fdbcbc4ba16a 100644 (file)
@@ -19,7 +19,7 @@ package org.apache.poi.hssf.record.formula.functions;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- * 
+ *
  */
 public abstract class MinaMaxa extends MultiOperandNumericFunction {
 
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Minute.java b/src/java/org/apache/poi/hssf/record/formula/functions/Minute.java
deleted file mode 100644 (file)
index a8b6836..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Minute extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Minverse.java b/src/java/org/apache/poi/hssf/record/formula/functions/Minverse.java
deleted file mode 100644 (file)
index 66f5647..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Minverse extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Mirr.java b/src/java/org/apache/poi/hssf/record/formula/functions/Mirr.java
deleted file mode 100644 (file)
index c87d113..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Mirr extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Mmult.java b/src/java/org/apache/poi/hssf/record/formula/functions/Mmult.java
deleted file mode 100644 (file)
index 95a4bf2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Mmult extends NotImplementedFunction {
-
-}
index c236ccee62cc72ab4fd2cf904ecbc9d71d2281c0..767e980c1c0604d7ded553a3bcf99e32293a9b3e 100644 (file)
@@ -34,15 +34,15 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- * 
+ *
  */
-public class Mode implements Function {
+public final class Mode implements Function {
 
        /**
         * if v is zero length or contains no duplicates, return value is
         * Double.NaN. Else returns the value that occurs most times and if there is
         * a tie, returns the first such value.
-        * 
+        *
         * @param v
         */
        public static double evaluate(double[] v) throws EvaluationException {
@@ -77,13 +77,13 @@ public class Mode implements Function {
        public Eval evaluate(Eval[] args, int srcCellRow, short srcCellCol) {
                double result;
                try {
-                       List temp = new ArrayList();
+                       List<Double> temp = new ArrayList<Double>();
                        for (int i = 0; i < args.length; i++) {
                                collectValues(args[i], temp);
                        }
                        double[] values = new double[temp.size()];
                        for (int i = 0; i < values.length; i++) {
-                               values[i] = ((Double) temp.get(i)).doubleValue();
+                               values[i] = temp.get(i).doubleValue();
                        }
                        result = evaluate(values);
                } catch (EvaluationException e) {
@@ -92,7 +92,7 @@ public class Mode implements Function {
                return new NumberEval(result);
        }
 
-       private static void collectValues(Eval arg, List temp) throws EvaluationException {
+       private static void collectValues(Eval arg, List<Double> temp) throws EvaluationException {
                if (arg instanceof AreaEval) {
                        AreaEval ae = (AreaEval) arg;
                        int width = ae.getWidth();
@@ -114,7 +114,7 @@ public class Mode implements Function {
 
        }
 
-       private static void collectValue(Eval arg, List temp, boolean mustBeNumber)
+       private static void collectValue(Eval arg, List<Double> temp, boolean mustBeNumber)
                        throws EvaluationException {
                if (arg instanceof ErrorEval) {
                        throw new EvaluationException((ErrorEval) arg);
index b3feac6a07a27437f321e6ed08207ac48f55cd7d..30b72ee74f36ec8cad65cc2548bb7013bca9505b 100644 (file)
@@ -45,7 +45,6 @@ public abstract class MultiOperandNumericFunction implements Function {
                _isBlankCounted = isBlankCounted;
        }
 
-
        static final double[] EMPTY_DOUBLE_ARRAY = { };
 
        private static class DoubleList {
@@ -102,7 +101,6 @@ public abstract class MultiOperandNumericFunction implements Function {
 
        protected abstract double evaluate(double[] values) throws EvaluationException;
 
-
        /**
         * Maximum number of operands accepted by this function.
         * Subclasses may override to change default value.
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/N.java b/src/java/org/apache/poi/hssf/record/formula/functions/N.java
deleted file mode 100644 (file)
index a5e65c3..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class N extends NotImplementedFunction {
-
-}
index eef0f451300b70d8513d5ee1fd0d196cefb63a3c..720b0c661f175395898e79499c4d4376ad4f66c3 100644 (file)
@@ -1,20 +1,19 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
 
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
 
 package org.apache.poi.hssf.record.formula.functions;
 
@@ -23,7 +22,7 @@ import org.apache.poi.hssf.record.formula.eval.Eval;
 
 /**
  * Implementation of Excel function NA()
- * 
+ *
  * @author Josh Micich
  */
 public final class Na implements Function {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Names.java b/src/java/org/apache/poi/hssf/record/formula/functions/Names.java
deleted file mode 100644 (file)
index 476156a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Names extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Negbinomdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Negbinomdist.java
deleted file mode 100644 (file)
index 0eb494b..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Negbinomdist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Normdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Normdist.java
deleted file mode 100644 (file)
index 3daca07..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Normdist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Norminv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Norminv.java
deleted file mode 100644 (file)
index 4a59482..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Norminv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Normsdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Normsdist.java
deleted file mode 100644 (file)
index 84d8aca..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Normsdist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Normsinv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Normsinv.java
deleted file mode 100644 (file)
index 161da9b..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Normsinv extends NotImplementedFunction {
-
-}
index b383e090df354c823377b83ec5d892b198af8ec7..46d1e7142a2a625187a5325ea8fba5f6024526d0 100644 (file)
@@ -45,7 +45,7 @@ public final class Not implements Function {
                } catch (EvaluationException e) {
                        return e.getErrorEval();
                }
-               
+
                return BoolEval.valueOf(!boolArgVal);
        }
 }
index 19643abf66af217df65c7be7881298167064a0e4..9c685d0f51f0a7dfb1b70ee7f39b04157ee02e1d 100644 (file)
@@ -21,15 +21,15 @@ import org.apache.poi.hssf.record.formula.eval.Eval;
 import org.apache.poi.ss.formula.eval.NotImplementedException;
 
 /**
- * 
+ *
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- * This is the default implementation of a Function class. 
- * The default behaviour is to raise a POI internal error 
- * ({@link NotImplementedException}). This error should alert 
+ * This is the default implementation of a Function class.
+ * The default behaviour is to raise a POI internal error
+ * ({@link NotImplementedException}). This error should alert
  * the user that the formula contained a function that is not
  * yet implemented.
  */
-public class NotImplementedFunction implements Function {
+public final class NotImplementedFunction implements Function {
        private final String _functionName;
        protected NotImplementedFunction() {
                _functionName = getClass().getName();
@@ -37,8 +37,11 @@ public class NotImplementedFunction implements Function {
        public NotImplementedFunction(String name) {
                _functionName = name;
        }
-       
+
        public Eval evaluate(Eval[] operands, int srcRow, short srcCol) {
                throw new NotImplementedException(_functionName);
        }
+       public String getFunctionName() {
+               return _functionName;
+       }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Note.java b/src/java/org/apache/poi/hssf/record/formula/functions/Note.java
deleted file mode 100644 (file)
index 210770a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Note extends NotImplementedFunction {
-
-}
index 70930a9dcba331ab1477cbcbfc78df09f61d9e3e..528d7f98abb5fcd242c01931d8bbc5ff7ec20b42 100644 (file)
@@ -17,6 +17,8 @@
 
 package org.apache.poi.hssf.record.formula.functions;
 
+import java.util.Date;
+
 import org.apache.poi.hssf.record.formula.eval.ErrorEval;
 import org.apache.poi.hssf.record.formula.eval.Eval;
 import org.apache.poi.hssf.record.formula.eval.NumberEval;
@@ -34,7 +36,7 @@ public final class Now implements Function {
                        return ErrorEval.VALUE_INVALID;
                }
 
-               java.util.Date now = new java.util.Date(System.currentTimeMillis());
+               Date now = new Date(System.currentTimeMillis());
                return new NumberEval(HSSFDateUtil.getExcelDate(now));
        }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Npv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Npv.java
deleted file mode 100644 (file)
index 9e57999..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Npv extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Numberstring.java b/src/java/org/apache/poi/hssf/record/formula/functions/Numberstring.java
deleted file mode 100644 (file)
index 5140341..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Numberstring extends NotImplementedFunction {
-
-}
index 9a702ee6a3467616b7c67d8b92f0e24918627762..136cf36630ab636dcd35fc2851a5388f90499da0 100644 (file)
@@ -60,8 +60,7 @@ public abstract class NumericFunction implements Function {
        protected abstract double eval(Eval[] args, int srcCellRow, short srcCellCol) throws EvaluationException;
 
        /* -------------------------------------------------------------------------- */
-       // intermediate sub-classes (one-arg, two-arg and multi-arg
-
+       // intermediate sub-classes (one-arg, two-arg and multi-arg)
 
        public static abstract class OneArg extends NumericFunction {
                protected OneArg() {
@@ -115,7 +114,6 @@ public abstract class NumericFunction implements Function {
 
        /* -------------------------------------------------------------------------- */
 
-
        public static final Function ABS = new OneArg() {
                protected double evaluate(double d) {
                        return Math.abs(d);
@@ -233,7 +231,6 @@ public abstract class NumericFunction implements Function {
                }
        };
 
-
        /* -------------------------------------------------------------------------- */
 
        public static final Function ATAN2 = new TwoArg() {
index 74eddac2de51ce9c96e0f97343eda4f6ffdaf1dd..4904c01d4734ee6ad533879b0ea127b0fe6ddd92 100644 (file)
 
 package org.apache.poi.hssf.record.formula.functions;
 
-
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- *  
+ *
  */
 public final class Odd extends NumericFunction.OneArg {
        private static final long PARITY_MASK = 0xFFFFFFFFFFFFFFFEL;
-    
+
        protected double evaluate(double d) {
                if (d==0) {
                        return 1;
                }
-               long result;
                if (d>0) {
-                       result = calcOdd(d);
-               } else {
-                       result = -calcOdd(-d);
+                       return calcOdd(d);
                }
-               return result;
-    }
+               return -calcOdd(-d);
+       }
 
        private static long calcOdd(double d) {
                double dpm1 = d+1;
index 086596ae21ac83543ca87436fb46f121cdf4b160..0fda540e3a3705849c63d3b6a1adc970bbe4230d 100644 (file)
@@ -29,10 +29,10 @@ import org.apache.poi.hssf.record.formula.eval.StringEval;
 import org.apache.poi.hssf.record.formula.eval.ValueEval;
 /**
  * Implementation for Excel function OFFSET()<p/>
- * 
- * OFFSET returns an area reference that is a specified number of rows and columns from a 
+ *
+ * OFFSET returns an area reference that is a specified number of rows and columns from a
  * reference cell or area.<p/>
- * 
+ *
  * <b>Syntax</b>:<br/>
  * <b>OFFSET</b>(<b>reference</b>, <b>rows</b>, <b>cols</b>, height, width)<p/>
  * <b>reference</b> is the base reference.<br/>
@@ -40,16 +40,16 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
  * <b>cols</b> is the number of columns left or right from the base reference.<br/>
  * <b>height</b> (default same height as base reference) is the row count for the returned area reference.<br/>
  * <b>width</b> (default same width as base reference) is the column count for the returned area reference.<br/>
- * 
+ *
  * @author Josh Micich
  */
 public final class Offset implements Function {
        // These values are specific to BIFF8
        private static final int LAST_VALID_ROW_INDEX = 0xFFFF;
        private static final int LAST_VALID_COLUMN_INDEX = 0xFF;
-       
 
-       /** 
+
+       /**
         * A one dimensional base + offset.  Represents either a row range or a column range.
         * Two instances of this class together specify an area range.
         */
@@ -66,7 +66,7 @@ public final class Offset implements Function {
                        _offset = offset;
                        _length = length;
                }
-               
+
                public short getFirstIndex() {
                        return (short) _offset;
                }
@@ -75,13 +75,13 @@ public final class Offset implements Function {
                }
                /**
                 * Moves the range by the specified translation amount.<p/>
-                * 
-                * This method also 'normalises' the range: Excel specifies that the width and height 
+                *
+                * This method also 'normalises' the range: Excel specifies that the width and height
                 * parameters (length field here) cannot be negative.  However, OFFSET() does produce
                 * sensible results in these cases.  That behavior is replicated here. <p/>
-                * 
+                *
                 * @param translationAmount may be zero negative or positive
-                * 
+                *
                 * @return the equivalent <tt>LinearOffsetRange</tt> with a positive length, moved by the
                 * specified translationAmount.
                 */
@@ -123,7 +123,7 @@ public final class Offset implements Function {
                private final int _height;
                private final RefEval _refEval;
                private final AreaEval _areaEval;
-               
+
                public BaseRef(RefEval re) {
                        _refEval = re;
                        _areaEval = null;
@@ -155,7 +155,7 @@ public final class Offset implements Function {
                        return _firstColumnIndex;
                }
 
-               public AreaEval offset(int relFirstRowIx, int relLastRowIx, 
+               public AreaEval offset(int relFirstRowIx, int relLastRowIx,
                                int relFirstColIx, int relLastColIx) {
                        if (_refEval == null) {
                                return _areaEval.offset(relFirstRowIx, relLastRowIx, relFirstColIx, relLastColIx);
@@ -163,12 +163,12 @@ public final class Offset implements Function {
                        return _refEval.offset(relFirstRowIx, relLastRowIx, relFirstColIx, relLastColIx);
                }
        }
-       
+
        public Eval evaluate(Eval[] args, int srcCellRow, short srcCellCol) {
                if(args.length < 3 || args.length > 5) {
                        return ErrorEval.VALUE_INVALID;
                }
-               
+
                try {
                        BaseRef baseRef = evaluateBaseRef(args[0]);
                        int rowOffset = evaluateIntArg(args[1], srcCellRow, srcCellCol);
@@ -193,11 +193,11 @@ public final class Offset implements Function {
                }
        }
 
-       private static AreaEval createOffset(BaseRef baseRef, 
+       private static AreaEval createOffset(BaseRef baseRef,
                        LinearOffsetRange orRow, LinearOffsetRange orCol) throws EvaluationException {
                LinearOffsetRange absRows = orRow.normaliseAndTranslate(baseRef.getFirstRowIndex());
                LinearOffsetRange absCols = orCol.normaliseAndTranslate(baseRef.getFirstColumnIndex());
-               
+
                if(absRows.isOutOfBounds(0, LAST_VALID_ROW_INDEX)) {
                        throw new EvaluationException(ErrorEval.REF_INVALID);
                }
@@ -208,7 +208,7 @@ public final class Offset implements Function {
        }
 
        private static BaseRef evaluateBaseRef(Eval eval) throws EvaluationException {
-               
+
                if(eval instanceof RefEval) {
                        return new BaseRef((RefEval)eval);
                }
@@ -239,10 +239,10 @@ public final class Offset implements Function {
                // but Math.floor() truncates toward negative infinity
                return (int)Math.floor(d);
        }
-       
+
        private static double evaluateDoubleArg(Eval eval, int srcCellRow, short srcCellCol) throws EvaluationException {
                ValueEval ve = OperandResolver.getSingleValue(eval, srcCellRow, srcCellCol);
-               
+
                if (ve instanceof NumericValueEval) {
                        return ((NumericValueEval) ve).getNumberValue();
                }
index 2d36037f5d49715c9cdaadff59b689b2a357fe57..bab77471aee6eed865a65d89878efa6ce4f9df8c 100644 (file)
@@ -18,7 +18,7 @@
 package org.apache.poi.hssf.record.formula.functions;
 
 /**
- * 
+ *
  */
 public final class Or extends BooleanFunction {
 
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Pearson.java b/src/java/org/apache/poi/hssf/record/formula/functions/Pearson.java
deleted file mode 100644 (file)
index dda597a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Pearson extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Percentile.java b/src/java/org/apache/poi/hssf/record/formula/functions/Percentile.java
deleted file mode 100644 (file)
index a3f59f1..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Percentile extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Percentrank.java b/src/java/org/apache/poi/hssf/record/formula/functions/Percentrank.java
deleted file mode 100644 (file)
index a47e4ff..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Percentrank extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Permut.java b/src/java/org/apache/poi/hssf/record/formula/functions/Permut.java
deleted file mode 100644 (file)
index e896f70..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Permut extends NotImplementedFunction {
-
-}
index 0713dc7ed6bcdf84f3a721b1bd49344d31fdff34..d69015b14847db728d1c228d1bd289815c530185 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 6, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.ErrorEval;
@@ -27,9 +24,9 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- *  
+ *
  */
-public class Pi implements Function {
+public final class Pi implements Function {
 
     private static final NumberEval PI_EVAL = new NumberEval(Math.PI);
 
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Poisson.java b/src/java/org/apache/poi/hssf/record/formula/functions/Poisson.java
deleted file mode 100644 (file)
index f4aba4c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Poisson extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Ppmt.java b/src/java/org/apache/poi/hssf/record/formula/functions/Ppmt.java
deleted file mode 100644 (file)
index 4e36630..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Ppmt extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Prob.java b/src/java/org/apache/poi/hssf/record/formula/functions/Prob.java
deleted file mode 100644 (file)
index 1229368..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Prob extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Proper.java b/src/java/org/apache/poi/hssf/record/formula/functions/Proper.java
deleted file mode 100644 (file)
index 26a8c3a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Proper extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Quartile.java b/src/java/org/apache/poi/hssf/record/formula/functions/Quartile.java
deleted file mode 100644 (file)
index ec81094..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Quartile extends NotImplementedFunction {
-
-}
index 4c180383d8c24f91005aecc28841af432a3346c9..c9940fffedb23db135a308d7b3ef7f6489b7e57f 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 6, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.ErrorEval;
@@ -27,9 +24,9 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- *  
+ *
  */
-public class Rand implements Function {
+public final class Rand implements Function {
 
     public Eval evaluate(Eval[] operands, int srcRow, short srcCol) {
         ValueEval retval;
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Rank.java b/src/java/org/apache/poi/hssf/record/formula/functions/Rank.java
deleted file mode 100644 (file)
index 2bb13d3..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Rank extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Rate.java b/src/java/org/apache/poi/hssf/record/formula/functions/Rate.java
deleted file mode 100644 (file)
index 485920c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Rate extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Reftext.java b/src/java/org/apache/poi/hssf/record/formula/functions/Reftext.java
deleted file mode 100644 (file)
index 3ba7bc9..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Reftext extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Relref.java b/src/java/org/apache/poi/hssf/record/formula/functions/Relref.java
deleted file mode 100644 (file)
index 7e7bee8..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Relref extends NotImplementedFunction {
-
-}
index 1dfc4f8f0571d55f9e9c6d6d9e002ed20ef6c8f1..8ff69491c6aee6817f68400a9a03dff3bedddedc 100644 (file)
@@ -24,7 +24,7 @@ import org.apache.poi.hssf.record.formula.eval.StringEval;
 import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
- * An implementation of the Excel REPLACE() function<p/>:
+ * An implementation of the Excel REPLACE() function:<p/>
  * Replaces part of a text string based on the number of characters
  * you specify, with another text string.<br/>
  *
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Replaceb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Replaceb.java
deleted file mode 100644 (file)
index 93d05bf..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Replaceb extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Rept.java b/src/java/org/apache/poi/hssf/record/formula/functions/Rept.java
deleted file mode 100644 (file)
index ce56e70..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Rept extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Request.java b/src/java/org/apache/poi/hssf/record/formula/functions/Request.java
deleted file mode 100644 (file)
index 23eeea5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Request extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Result.java b/src/java/org/apache/poi/hssf/record/formula/functions/Result.java
deleted file mode 100644 (file)
index c15f242..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Result extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Rightb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Rightb.java
deleted file mode 100644 (file)
index 4ee99fd..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Rightb extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Roman.java b/src/java/org/apache/poi/hssf/record/formula/functions/Roman.java
deleted file mode 100644 (file)
index c2db7e8..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Roman extends NotImplementedFunction {
-
-}
index d111d594b564fe071baa5123637ce238909b5cc5..ac164012620c96d0afeecd3ba03145a3abe3ab0b 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.AreaEval;
@@ -27,12 +24,12 @@ import org.apache.poi.hssf.record.formula.eval.NumberEval;
 import org.apache.poi.hssf.record.formula.eval.RefEval;
 import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
-public class Row implements Function {
+public final class Row implements Function {
 
     public Eval evaluate(Eval[] evals, int srcCellRow, short srcCellCol) {
         ValueEval retval = null;
         int rnum = -1;
-        
+
         switch (evals.length) {
         default:
             retval = ErrorEval.VALUE_INVALID;
@@ -52,14 +49,14 @@ public class Row implements Function {
         case 0:
             rnum = srcCellRow;
         }
-        
+
         if (retval == null) {
             retval = (rnum >= 0)
                     ? new NumberEval(rnum + 1) // +1 since excel rownums are 1 based
                     : (ValueEval) ErrorEval.VALUE_INVALID;
         }
-        
+
         return retval;
     }
-    
+
 }
index aabffab2f6a8867d5e2c07555d021670440c5ad2..9f331f47d73dd8a4861c66653b5b384a0b7491cc 100644 (file)
@@ -1,20 +1,19 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
 
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
 
 package org.apache.poi.hssf.record.formula.functions;
 
@@ -26,7 +25,7 @@ import org.apache.poi.hssf.record.formula.eval.RefEval;
 
 /**
  * Implementation for Excel ROWS function.
- * 
+ *
  * @author Josh Micich
  */
 public final class Rows implements Function {
@@ -44,16 +43,16 @@ public final class Rows implements Function {
                                return ErrorEval.VALUE_INVALID;
                }
                Eval firstArg = args[0];
-               
+
                int result;
-        if (firstArg instanceof AreaEval) {
-            AreaEval ae = (AreaEval) firstArg;
-            result = ae.getLastRow() - ae.getFirstRow() + 1;
-        } else if (firstArg instanceof RefEval) {
-            result = 1;
-        } else { // anything else is not valid argument
-            return ErrorEval.VALUE_INVALID;
-        }
-        return new NumberEval(result);
+               if (firstArg instanceof AreaEval) {
+                       AreaEval ae = (AreaEval) firstArg;
+                       result = ae.getLastRow() - ae.getFirstRow() + 1;
+               } else if (firstArg instanceof RefEval) {
+                       result = 1;
+               } else { // anything else is not valid argument
+                       return ErrorEval.VALUE_INVALID;
+               }
+               return new NumberEval(result);
        }
 }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Rsq.java b/src/java/org/apache/poi/hssf/record/formula/functions/Rsq.java
deleted file mode 100644 (file)
index f1addc3..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Rsq extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Search.java b/src/java/org/apache/poi/hssf/record/formula/functions/Search.java
deleted file mode 100644 (file)
index 351495c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Search extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Searchb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Searchb.java
deleted file mode 100644 (file)
index 3dfa711..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Searchb extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Second.java b/src/java/org/apache/poi/hssf/record/formula/functions/Second.java
deleted file mode 100644 (file)
index 3ebd553..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Second extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Series.java b/src/java/org/apache/poi/hssf/record/formula/functions/Series.java
deleted file mode 100644 (file)
index 3e60685..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Series extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Setname.java b/src/java/org/apache/poi/hssf/record/formula/functions/Setname.java
deleted file mode 100644 (file)
index 5f01782..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Setname extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Setvalue.java b/src/java/org/apache/poi/hssf/record/formula/functions/Setvalue.java
deleted file mode 100644 (file)
index c86e65e..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Setvalue extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Skew.java b/src/java/org/apache/poi/hssf/record/formula/functions/Skew.java
deleted file mode 100644 (file)
index bb6d259..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Skew extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Sln.java b/src/java/org/apache/poi/hssf/record/formula/functions/Sln.java
deleted file mode 100644 (file)
index dfb8176..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Sln extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Slope.java b/src/java/org/apache/poi/hssf/record/formula/functions/Slope.java
deleted file mode 100644 (file)
index fb631f5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Slope extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Standardize.java b/src/java/org/apache/poi/hssf/record/formula/functions/Standardize.java
deleted file mode 100644 (file)
index 6fa1df5..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Standardize extends NotImplementedFunction {
-
-}
index e78f38caaa0b770ade45ce0daa6857d9377e6405..2cc4a78f374947f351f716e39b488b9e9271e304 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 30, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import java.util.Arrays;
@@ -27,9 +24,11 @@ import java.util.Arrays;
  *
  * Library for common statistics functions
  */
-public final class StatsLib {
+final class StatsLib {
 
-    private StatsLib() {}
+    private StatsLib() {
+        // no instances of this class
+    }
 
 
     /**
@@ -51,7 +50,7 @@ public final class StatsLib {
         r = s / v.length;
         return r;
     }
-    
+
     public static double stdev(double[] v) {
         double r = Double.NaN;
         if (v!=null && v.length > 1) {
@@ -59,11 +58,11 @@ public final class StatsLib {
         }
         return r;
     }
-    
-    
+
+
     public static double median(double[] v) {
         double r = Double.NaN;
-        
+
         if (v!=null && v.length >= 1) {
             int n = v.length;
             Arrays.sort(v);
@@ -71,11 +70,11 @@ public final class StatsLib {
                 ? (v[n / 2] + v[n / 2 - 1]) / 2
                 : v[n / 2];
         }
-        
+
         return r;
     }
-    
-    
+
+
     public static double devsq(double[] v) {
         double r = Double.NaN;
         if (v!=null && v.length >= 1) {
@@ -90,14 +89,14 @@ public final class StatsLib {
             for (int i=0; i<n; i++) {
                 s += (v[i]- m) * (v[i] - m);
             }
-            
+
             r = (n == 1)
                     ? 0
                     : s;
         }
         return r;
     }
-    
+
     /**
      * returns the kth largest element in the array. Duplicates
      * are considered as distinct values. Hence, eg.
@@ -105,15 +104,13 @@ public final class StatsLib {
      * <br/>
      * k <= 0 & k >= v.length and null or empty arrays
      * will result in return value Double.NaN
-     * @param v
-     * @param k
      */
     public static double kthLargest(double[] v, int k) {
         double r = Double.NaN;
-        k--; // since arrays are 0-based
-        if (v!=null && v.length > k && k >= 0) {
+        int index = k-1; // since arrays are 0-based
+        if (v!=null && v.length > index && index >= 0) {
             Arrays.sort(v);
-            r = v[v.length-k-1];
+            r = v[v.length-index-1];
         }
         return r;
     }
@@ -130,10 +127,10 @@ public final class StatsLib {
      */
     public static double kthSmallest(double[] v, int k) {
         double r = Double.NaN;
-        k--; // since arrays are 0-based
-        if (v!=null && v.length > k && k >= 0) {
+        int index = k-1; // since arrays are 0-based
+        if (v!=null && v.length > index && index >= 0) {
             Arrays.sort(v);
-            r = v[k];
+            r = v[index];
         }
         return r;
     }
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Stdeva.java b/src/java/org/apache/poi/hssf/record/formula/functions/Stdeva.java
deleted file mode 100644 (file)
index 50306a2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Stdeva extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Stdevp.java b/src/java/org/apache/poi/hssf/record/formula/functions/Stdevp.java
deleted file mode 100644 (file)
index c270c3c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Stdevp extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Stdevpa.java b/src/java/org/apache/poi/hssf/record/formula/functions/Stdevpa.java
deleted file mode 100644 (file)
index 2554b22..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Stdevpa extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Step.java b/src/java/org/apache/poi/hssf/record/formula/functions/Step.java
deleted file mode 100644 (file)
index 3febcca..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Step extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Steyx.java b/src/java/org/apache/poi/hssf/record/formula/functions/Steyx.java
deleted file mode 100644 (file)
index d92f3ef..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Steyx extends NotImplementedFunction {
-
-}
index b00d7510e319c77b372ee6f3871e65a779ab7c54..2cd3a719c4b3b6aa26fcc4a54c87a4ed5a941060 100644 (file)
@@ -24,7 +24,7 @@ import org.apache.poi.hssf.record.formula.eval.StringEval;
 import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
- * An implementation of the SUBSTITUTE function:
+ * An implementation of the SUBSTITUTE function:<P/>
  * Substitutes text in a text string with new text, some number of times.
  * @author Manda Wilson &lt; wilson at c bio dot msk cc dot org &gt;
  */
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Subtotal.java b/src/java/org/apache/poi/hssf/record/formula/functions/Subtotal.java
deleted file mode 100644 (file)
index ddfa3ad..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Subtotal extends NotImplementedFunction {
-
-}
index 5255cda28503b05049364218ae39515f79024eb1..8eb2565d8921c59adc3ceaaba57774af4774e505 100644 (file)
@@ -28,7 +28,7 @@ import org.apache.poi.hssf.record.formula.functions.CountUtils.I_MatchPredicate;
 
 /**
  * Implementation for the Excel function SUMIF<p>
- * 
+ *
  * Syntax : <br/>
  *  SUMIF ( <b>range</b>, <b>criteria</b>, sum_range ) <br/>
  *    <table border="0" cellpadding="1" cellspacing="0" summary="Parameter descriptions">
@@ -45,12 +45,12 @@ public final class Sumif implements Function {
                if (args.length < 2) {
                        return ErrorEval.VALUE_INVALID;
                }
-               
+
                AreaEval aeRange;
                AreaEval aeSum;
                try {
                        aeRange = convertRangeArg(args[0]);
-                       
+
                        switch (args.length) {
                                case 2:
                                        aeSum = aeRange;
@@ -72,7 +72,7 @@ public final class Sumif implements Function {
        private static double sumMatchingCells(AreaEval aeRange, I_MatchPredicate mp, AreaEval aeSum) {
                int height=aeRange.getHeight();
                int width= aeRange.getWidth();
-               
+
                double result = 0.0;
                for (int r=0; r<height; r++) {
                        for (int c=0; c<width; c++) {
@@ -84,7 +84,7 @@ public final class Sumif implements Function {
 
        private static double accumulate(AreaEval aeRange, I_MatchPredicate mp, AreaEval aeSum, int relRowIndex,
                        int relColIndex) {
-               
+
                if (!mp.matches(aeRange.getRelativeValue(relRowIndex, relColIndex))) {
                        return 0.0;
                }
index c437ba58945f63972952d3e8c02a2c2809c78eff..572c67f9265f094594b9d17028b2573d503b16e3 100644 (file)
@@ -1,20 +1,19 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
 
 package org.apache.poi.hssf.record.formula.functions;
 
@@ -32,23 +31,23 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * Implementation for the Excel function SUMPRODUCT<p>
- * 
+ *
  * Syntax : <br/>
  *  SUMPRODUCT ( array1[, array2[, array3[, ...]]])
  *    <table border="0" cellpadding="1" cellspacing="0" summary="Parameter descriptions">
- *      <tr><th>array1, ... arrayN&nbsp;&nbsp;</th><td>typically area references, 
+ *      <tr><th>array1, ... arrayN&nbsp;&nbsp;</th><td>typically area references,
  *      possibly cell references or scalar values</td></tr>
  *    </table><br/>
- *    
- * Let A<b>n</b><sub>(<b>i</b>,<b>j</b>)</sub> represent the element in the <b>i</b>th row <b>j</b>th column 
- * of the <b>n</b>th array<br/>   
- * Assuming each array has the same dimensions (W, H), the result is defined as:<br/>    
+ *
+ * Let A<b>n</b><sub>(<b>i</b>,<b>j</b>)</sub> represent the element in the <b>i</b>th row <b>j</b>th column
+ * of the <b>n</b>th array<br/>
+ * Assuming each array has the same dimensions (W, H), the result is defined as:<br/>
  * SUMPRODUCT = &Sigma;<sub><b>i</b>: 1..H</sub> &nbsp;
  *     (&nbsp; &Sigma;<sub><b>j</b>: 1..W</sub> &nbsp;
- *       (&nbsp; &Pi;<sub><b>n</b>: 1..N</sub> 
+ *       (&nbsp; &Pi;<sub><b>n</b>: 1..N</sub>
  *                     A<b>n</b><sub>(<b>i</b>,<b>j</b>)</sub>&nbsp;
  *    )&nbsp;
- *  ) 
+ *  )
  * </p>
  * @author Josh Micich
  */
@@ -56,9 +55,9 @@ public final class Sumproduct implements Function {
 
 
        public Eval evaluate(Eval[] args, int srcCellRow, short srcCellCol) {
-               
+
                int maxN = args.length;
-               
+
                if(maxN < 1) {
                        return ErrorEval.VALUE_INVALID;
                }
@@ -80,7 +79,7 @@ public final class Sumproduct implements Function {
                } catch (EvaluationException e) {
                        return e.getErrorEval();
                }
-               throw new RuntimeException("Invalid arg type for SUMPRODUCT: (" 
+               throw new RuntimeException("Invalid arg type for SUMPRODUCT: ("
                                + firstArg.getClass().getName() + ")");
        }
 
@@ -96,7 +95,7 @@ public final class Sumproduct implements Function {
        }
 
        private static double getScalarValue(Eval arg) throws EvaluationException {
-               
+
                Eval eval;
                if (arg instanceof RefEval) {
                        RefEval re = (RefEval) arg;
@@ -104,7 +103,7 @@ public final class Sumproduct implements Function {
                } else {
                        eval = arg;
                }
-               
+
                if (eval == null) {
                        throw new RuntimeException("parameter may not be null");
                }
@@ -118,10 +117,10 @@ public final class Sumproduct implements Function {
                }
 
                if (!(eval instanceof ValueEval)) {
-                       throw new RuntimeException("Unexpected value eval class (" 
+                       throw new RuntimeException("Unexpected value eval class ("
                                        + eval.getClass().getName() + ")");
                }
-               
+
                return getProductTerm((ValueEval) eval, true);
        }
 
@@ -135,15 +134,15 @@ public final class Sumproduct implements Function {
                        return ErrorEval.VALUE_INVALID;
                }
 
-               
+
                AreaEval firstArg = args[0];
-               
+
                int height = firstArg.getHeight();
                int width = firstArg.getWidth(); // TODO - junit
-               
+
                // first check dimensions
                if (!areasAllSameSize(args, height, width)) {
-                       // normally this results in #VALUE!, 
+                       // normally this results in #VALUE!,
                        // but errors in individual cells take precedence
                        for (int i = 1; i < args.length; i++) {
                                throwFirstError(args[i]);
@@ -152,7 +151,7 @@ public final class Sumproduct implements Function {
                }
 
                double acc = 0;
-               
+
                for (int rrIx=0; rrIx<height; rrIx++) {
                        for (int rcIx=0; rcIx<width; rcIx++) {
                                double term = 1D;
@@ -163,7 +162,7 @@ public final class Sumproduct implements Function {
                                acc += term;
                        }
                }
-               
+
                return new NumberEval(acc);
        }
 
@@ -196,11 +195,11 @@ public final class Sumproduct implements Function {
 
 
        /**
-        * Determines a <code>double</code> value for the specified <code>ValueEval</code>. 
+        * Determines a <code>double</code> value for the specified <code>ValueEval</code>.
         * @param isScalarProduct <code>false</code> for SUMPRODUCTs over area refs.
         * @throws EvaluationException if <code>ve</code> represents an error value.
         * <p/>
-        * Note - string values and empty cells are interpreted differently depending on 
+        * Note - string values and empty cells are interpreted differently depending on
         * <code>isScalarProduct</code>.  For scalar products, if any term is blank or a string, the
         * error (#VALUE!) is raised.  For area (sum)products, if any term is blank or a string, the
         * result is zero.
@@ -215,7 +214,7 @@ public final class Sumproduct implements Function {
                        }
                        return 0;
                }
-               
+
                if(ve instanceof ErrorEval) {
                        throw new EvaluationException((ErrorEval)ve);
                }
@@ -231,7 +230,7 @@ public final class Sumproduct implements Function {
                        NumericValueEval nve = (NumericValueEval) ve;
                        return nve.getNumberValue();
                }
-               throw new RuntimeException("Unexpected value eval class (" 
+               throw new RuntimeException("Unexpected value eval class ("
                                + ve.getClass().getName() + ")");
        }
 }
index 4dedf26574859fdef3f26b4a0c5138f4ff685aa7..b27116966647cc94f3eb61ed08f1b0b266a2f6f7 100644 (file)
@@ -20,14 +20,14 @@ package org.apache.poi.hssf.record.formula.functions;
 
 /**
  * Implementation of Excel function SUMX2MY2()<p/>
- * 
+ *
  * Calculates the sum of differences of squares in two arrays of the same size.<br/>
  * <b>Syntax</b>:<br/>
  * <b>SUMX2MY2</b>(<b>arrayX</b>, <b>arrayY</b>)<p/>
- * 
+ *
  * result = &Sigma;<sub>i: 0..n</sub>(x<sub>i</sub><sup>2</sup>-y<sub>i</sub><sup>2</sup>)
- * 
- * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; 
+ *
+ * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  */
 public final class Sumx2my2 extends XYNumericFunction {
 
index c3af0bd3802b8b71c0b1f8277bf64f453fb1cfed..3cedca35e2c5601b5e9a01e61f96564987cf7a00 100644 (file)
@@ -20,14 +20,14 @@ package org.apache.poi.hssf.record.formula.functions;
 
 /**
  * Implementation of Excel function SUMX2PY2()<p/>
- * 
+ *
  * Calculates the sum of squares in two arrays of the same size.<br/>
  * <b>Syntax</b>:<br/>
  * <b>SUMX2PY2</b>(<b>arrayX</b>, <b>arrayY</b>)<p/>
- * 
+ *
  * result = &Sigma;<sub>i: 0..n</sub>(x<sub>i</sub><sup>2</sup>+y<sub>i</sub><sup>2</sup>)
- * 
- * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; 
+ *
+ * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  */
 public final class Sumx2py2 extends XYNumericFunction {
 
index 4fa11e36ba77ab9f658abc71fb9f1f5bc38cb9dc..bb95c9fdf614f30d5b0a0ffaf584f1fca84cf4f2 100644 (file)
@@ -19,14 +19,14 @@ package org.apache.poi.hssf.record.formula.functions;
 
 /**
  * Implementation of Excel function SUMXMY2()<p/>
- * 
+ *
  * Calculates the sum of squares of differences between two arrays of the same size.<br/>
  * <b>Syntax</b>:<br/>
  * <b>SUMXMY2</b>(<b>arrayX</b>, <b>arrayY</b>)<p/>
- * 
+ *
  * result = &Sigma;<sub>i: 0..n</sub>(x<sub>i</sub>-y<sub>i</sub>)<sup>2</sup>
- * 
- * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; 
+ *
+ * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
  */
 public final class Sumxmy2 extends XYNumericFunction {
 
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Syd.java b/src/java/org/apache/poi/hssf/record/formula/functions/Syd.java
deleted file mode 100644 (file)
index 45347f2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Syd extends NotImplementedFunction {
-
-}
index b322cd985c32da0c59d3cc76e190e8a6bae55411..9d764c33bc0903731be344db858b39f0dbac069f 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.ErrorEval;
@@ -39,12 +36,12 @@ public final class T implements Function {
             RefEval re = (RefEval) arg;
             arg = re.getInnerValueEval();
         }
-        
+
         if (arg instanceof StringEval) {
             // Text values are returned unmodified
             return arg;
         }
-        
+
         if (arg instanceof ErrorEval) {
             // Error values also returned unmodified
             return arg;
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Tdist.java b/src/java/org/apache/poi/hssf/record/formula/functions/Tdist.java
deleted file mode 100644 (file)
index d2a76de..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Tdist extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Text.java b/src/java/org/apache/poi/hssf/record/formula/functions/Text.java
deleted file mode 100644 (file)
index 833fa82..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Text extends NotImplementedFunction {
-
-}
index be269d93dc0c0fa15875f4d9c714fe62043fcce5..5fd758962df3e251d6c409655d9ed97ec2ab9ca8 100644 (file)
@@ -54,7 +54,7 @@ public abstract class TextFunction implements Function {
        protected abstract ValueEval evaluateFunc(Eval[] args, int srcCellRow, short srcCellCol) throws EvaluationException;
 
        /* ---------------------------------------------------------------------- */
-       
+
        private static abstract class SingleArgTextFunc extends TextFunction {
 
                protected SingleArgTextFunc() {
@@ -102,10 +102,10 @@ public abstract class TextFunction implements Function {
         * An implementation of the MID function<br/>
         * MID returns a specific number of
         * characters from a text string, starting at the specified position.<p/>
-        * 
+        *
         * <b>Syntax<b>:<br/> <b>MID</b>(<b>text</b>, <b>start_num</b>,
         * <b>num_chars</b>)<br/>
-        * 
+        *
         * Author: Manda Wilson &lt; wilson at c bio dot msk cc dot org &gt;
         */
        public static final Function MID = new TextFunction() {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Textref.java b/src/java/org/apache/poi/hssf/record/formula/functions/Textref.java
deleted file mode 100644 (file)
index 8fa2514..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Textref extends NotImplementedFunction {
-
-}
index 764e166436dd1a8e038239ff00743ef7c8a6b358..1ddb8516ffba0b1632f704dbc54f650faee64a67 100644 (file)
@@ -43,7 +43,7 @@ public final class Time implements Function {
                        return ErrorEval.VALUE_INVALID;
                }
                double result;
-               
+
                try {
                        result = evaluate(evalArg(args[0]), evalArg(args[1]), evalArg(args[2]));
                } catch (EvaluationException e) {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Timevalue.java b/src/java/org/apache/poi/hssf/record/formula/functions/Timevalue.java
deleted file mode 100644 (file)
index 049bd30..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Timevalue extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Tinv.java b/src/java/org/apache/poi/hssf/record/formula/functions/Tinv.java
deleted file mode 100644 (file)
index dab7dcd..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Tinv extends NotImplementedFunction {
-
-}
index b70741213611bbd4f087145948f4c19d609da998..b71fce46111055586ebeb96aa3a04de9a5277250 100644 (file)
@@ -27,10 +27,10 @@ import org.apache.poi.hssf.usermodel.HSSFDateUtil;
 
 /**
  * Implementation of Excel TODAY() Function<br/>
- * 
+ *
  * @author Frank Taffelt
  */
-public class Today implements Function {
+public final class Today implements Function {
 
        public Eval evaluate(Eval[] evals, int srcCellRow, short srcCellCol) {
                if (evals.length > 0) {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Transpose.java b/src/java/org/apache/poi/hssf/record/formula/functions/Transpose.java
deleted file mode 100644 (file)
index cd414ff..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Transpose extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Trend.java b/src/java/org/apache/poi/hssf/record/formula/functions/Trend.java
deleted file mode 100644 (file)
index 80cece9..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Trend extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Trimmean.java b/src/java/org/apache/poi/hssf/record/formula/functions/Trimmean.java
deleted file mode 100644 (file)
index 4775a9e..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Trimmean extends NotImplementedFunction {
-
-}
index 78df7776a130c129f69dc875704e86ec1ef8f565..429cc5f0d5f650ae0a4ce7b808b58a584c5bbd5b 100644 (file)
@@ -1,23 +1,20 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 6, 2005
- *
- */
+/* ====================================================================
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   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 obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+==================================================================== */
+
 package org.apache.poi.hssf.record.formula.functions;
 
 import org.apache.poi.hssf.record.formula.eval.BoolEval;
@@ -27,9 +24,9 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- *  
+ *
  */
-public class True implements Function {
+public final class True implements Function {
 
     public Eval evaluate(Eval[] operands, int srcRow, short srcCol) {
         ValueEval retval;
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Trunc.java b/src/java/org/apache/poi/hssf/record/formula/functions/Trunc.java
deleted file mode 100644 (file)
index 65fedd1..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Trunc extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Ttest.java b/src/java/org/apache/poi/hssf/record/formula/functions/Ttest.java
deleted file mode 100644 (file)
index b453043..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Ttest extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Type.java b/src/java/org/apache/poi/hssf/record/formula/functions/Type.java
deleted file mode 100644 (file)
index 4230382..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Type extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Usdollar.java b/src/java/org/apache/poi/hssf/record/formula/functions/Usdollar.java
deleted file mode 100644 (file)
index 3baf71c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Usdollar extends NotImplementedFunction {
-
-}
index 84f61db98e7b79539015fc52a15acefda7739a10..0dbfdb52de412041fdd49428c878145794f86256 100644 (file)
@@ -26,14 +26,14 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 
 /**
  * Implementation for Excel VALUE() function.<p/>
- * 
+ *
  * <b>Syntax</b>:<br/> <b>VALUE</b>(<b>text</b>)<br/>
- * 
+ *
  * Converts the text argument to a number. Leading and/or trailing whitespace is
  * ignored. Currency symbols and thousands separators are stripped out.
  * Scientific notation is also supported. If the supplied text does not convert
  * properly the result is <b>#VALUE!</b> error. Blank string converts to zero.
- * 
+ *
  * @author Josh Micich
  */
 public final class Value implements Function {
@@ -61,8 +61,8 @@ public final class Value implements Function {
        }
 
        /**
-        * TODO see if the same functionality is needed in {@link OperandResolver#parseDouble(String)} 
-        * 
+        * TODO see if the same functionality is needed in {@link OperandResolver#parseDouble(String)}
+        *
         * @return <code>null</code> if there is any problem converting the text
         */
        private static Double convertTextToNumber(String strText) {
@@ -156,7 +156,7 @@ public final class Value implements Function {
                                        lastThousandsSeparatorIndex = i;
                                        // don't append ','
                                        continue;
-       
+
                                case 'E':
                                case 'e':
                                        if (i - lastThousandsSeparatorIndex < MIN_DISTANCE_BETWEEN_THOUSANDS_SEPARATOR) {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Var.java b/src/java/org/apache/poi/hssf/record/formula/functions/Var.java
deleted file mode 100644 (file)
index 2b0a3b6..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Var extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Vara.java b/src/java/org/apache/poi/hssf/record/formula/functions/Vara.java
deleted file mode 100644 (file)
index c484c5a..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Vara extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Varp.java b/src/java/org/apache/poi/hssf/record/formula/functions/Varp.java
deleted file mode 100644 (file)
index e8c8bd3..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Varp extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Varpa.java b/src/java/org/apache/poi/hssf/record/formula/functions/Varpa.java
deleted file mode 100644 (file)
index 290b97d..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Varpa extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Vdb.java b/src/java/org/apache/poi/hssf/record/formula/functions/Vdb.java
deleted file mode 100644 (file)
index 5fb594d..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Vdb extends NotImplementedFunction {
-
-}
index 28923c0f374eea8c09707a1589807a41b6b1f459..27d16ee86702fb720a8f193f51350fd92ed44df1 100644 (file)
@@ -26,22 +26,22 @@ import org.apache.poi.hssf.record.formula.eval.ValueEval;
 import org.apache.poi.hssf.record.formula.functions.LookupUtils.ValueVector;
 /**
  * Implementation of the VLOOKUP() function.<p/>
- * 
+ *
  * VLOOKUP finds a row in a lookup table by the first column value and returns the value from another column.<br/>
- * 
+ *
  * <b>Syntax</b>:<br/>
  * <b>VLOOKUP</b>(<b>lookup_value</b>, <b>table_array</b>, <b>col_index_num</b>, range_lookup)<p/>
- * 
+ *
  * <b>lookup_value</b>  The value to be found in the first column of the table array.<br/>
  * <b>table_array</b> An area reference for the lookup data. <br/>
  * <b>col_index_num</b> a 1 based index specifying which column value of the lookup data will be returned.<br/>
- * <b>range_lookup</b> If TRUE (default), VLOOKUP finds the largest value less than or equal to 
- * the lookup_value.  If FALSE, only exact matches will be considered<br/>   
- * 
+ * <b>range_lookup</b> If TRUE (default), VLOOKUP finds the largest value less than or equal to
+ * the lookup_value.  If FALSE, only exact matches will be considered<br/>
+ *
  * @author Josh Micich
  */
 public final class Vlookup implements Function {
-       
+
        public Eval evaluate(Eval[] args, int srcCellRow, short srcCellCol) {
                Eval arg3 = null;
                switch(args.length) {
@@ -71,9 +71,9 @@ public final class Vlookup implements Function {
 
        /**
         * Returns one column from an <tt>AreaEval</tt>
-        * 
+        *
         * @param colIndex assumed to be non-negative
-        * 
+        *
         * @throws EvaluationException (#REF!) if colIndex is too high
         */
        private ValueVector createResultColumnVector(AreaEval tableArray, int colIndex) throws EvaluationException {
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Volatile.java b/src/java/org/apache/poi/hssf/record/formula/functions/Volatile.java
deleted file mode 100644 (file)
index 734eb0f..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Volatile extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Weekday.java b/src/java/org/apache/poi/hssf/record/formula/functions/Weekday.java
deleted file mode 100644 (file)
index 7de5f95..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Weekday extends NotImplementedFunction {
-
-}
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Weibull.java b/src/java/org/apache/poi/hssf/record/formula/functions/Weibull.java
deleted file mode 100644 (file)
index b2a4895..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Weibull extends NotImplementedFunction {
-
-}
index 1d83b363fda3fe5169a409f2cdc8c4a4c5f94481..5c80068fff726d3680b49d7a2097a1d018d99ba7 100644 (file)
@@ -28,7 +28,7 @@ import org.apache.poi.hssf.record.formula.functions.LookupUtils.ValueVector;
 
 /**
  * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
- * 
+ *
  */
 public abstract class XYNumericFunction implements Function {
 
diff --git a/src/java/org/apache/poi/hssf/record/formula/functions/Ztest.java b/src/java/org/apache/poi/hssf/record/formula/functions/Ztest.java
deleted file mode 100644 (file)
index ed12b63..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* 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 obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-/*
- * Created on May 15, 2005
- *
- */
-package org.apache.poi.hssf.record.formula.functions;
-
-public class Ztest extends NotImplementedFunction {
-
-}
index d9571852497dc99c7b31bae104a62e014712697a..783294e9d3b2ad6df1bbbc61be77a47bc87256b7 100644 (file)
@@ -458,54 +458,6 @@ public class TestMathX extends AbstractNumericTestCase {
         
     }
 
-    public void testSumproduct() {
-        double d = 0;
-        double[][] darr = new double[][]
-               {{0   ,0.11   ,23.23},
-                {1  ,0.22   ,46.46},
-                {2  ,0.33   ,69.69},
-                {3  ,0.44   ,92.92},
-                {4  ,0.55   ,116.15},
-                {5  ,0.66   ,139.38},
-                {6  ,0.77   ,162.61},
-                {7  ,0.88   ,185.84},
-                {8  ,0.99   ,209.07},
-                {9  ,1.1    ,232.3},
-                {10 ,1.21   ,255.53}};
-        d = MathX.sumproduct(darr);
-        assertEquals("Sumproduct ", 4.243234425E+22, d);
-        darr = new double[][]
-               {{0  ,0.11   ,23.23},
-                {0  ,0.22   ,46.46},
-                {0  ,0.33   ,69.69},
-                {0  ,0.44   ,92.92},
-                {0  ,0.55   ,116.15},
-                {0  ,0.66   ,139.38},
-                {0  ,0.77   ,162.61},
-                {0  ,0.88   ,185.84},
-                {0  ,0.99   ,209.07},
-                {0  ,1.1    ,232.3},
-                {0  ,1.21   ,255.53}};
-        d = MathX.sumproduct(darr);
-        assertEquals("Sumproduct ", 4.243234425E+22, d);
-        
-        darr = new double[][]
-               {{0, 0, 0, 0, 0, 0, 0, 0},
-                {0.11, 0.22, 0.33, 0.44, 0.55, 0.66, 0.77, 0.88},
-                {23.23, 46.46, 69.69, 92.92, 116.15, 139.38, 162.61, 185.84}};
-        d = MathX.sumproduct(darr);
-        assertEquals("Sumproduct ", 0, d);
-
-        darr = new double[][]
-               {{0, 1, 2, 3, 4, 5, 6, 7},
-                {0.11, 0.22, 0.33, 0.44, 0.55, 0.66, 0.77, 0.88},
-                {23.23, 46.46, 69.69, 92.92, 116.15, 139.38, 162.61, 185.84}};
-        d = MathX.sumproduct(darr);
-        assertEquals("Sumproduct ", 2790.3876, d);
-
-        
-    }
-
     public void testSumsq() {
         double[] d = new double[100];
         d[0] = 1.1;     d[1] = 2.1;     d[2] = 3.1;     d[3] = 4.1;