/** * Adds this formula to the list of formulas, if it falls within * the bounds * * @param fr the formula record to test for membership of this group * @return TRUE if the formulas was added, FALSE otherwise */ public boolean add(BaseSharedFormulaRecord fr) { boolean added = false; int r = fr.getRow(); if (r >= firstRow && r <= lastRow) { int c = fr.getColumn(); if (c >= firstCol && c <= lastCol) { formulas.add(fr); added = true; } } return added; }
templateFormula.setTokens(tokens); NumberFormat templateNumberFormat = null; if (templateFormula.getType() == CellType.NUMBER_FORMULA) templateNumberFormat = snfr.getNumberFormat(); if (fr.isDate(templateFormula.getXFIndex())) templateFormula.setTokens(snfr.getTokens()); if (f.getType() == CellType.NUMBER_FORMULA) if (fr.isDate(f.getXFIndex())) f.setTokens(tokens); sfs[i + 1] = f;
excelFile.setPos(f.getFilePos()); FormulaRecord fr = new FormulaRecord(f.getRecord(), excelFile, formattingRecords,
/** * Gets the formula as an excel string * * @return the formula as an excel string * @exception FormulaException */ public String getFormula() throws FormulaException { if (formulaString == null) { FormulaParser fp = new FormulaParser (tokens, this, externalSheet, nameTable, getSheet().getWorkbook().getSettings()); fp.parse(); formulaString = fp.getFormula(); } return formulaString; }
templateFormula.setTokens(tokens); NumberFormat templateNumberFormat = null; if (templateFormula.getType() == CellType.NUMBER_FORMULA) templateNumberFormat = snfr.getNumberFormat(); if (fr.isDate(templateFormula.getXFIndex())) templateFormula.setTokens(snfr.getTokens()); if (f.getType() == CellType.NUMBER_FORMULA) if (fr.isDate(f.getXFIndex())) f.setTokens(tokens); sfs[i + 1] = f;
excelFile.setPos(f.getFilePos()); FormulaRecord fr = new FormulaRecord(f.getRecord(), excelFile, formattingRecords,
/** * Gets the formula as an excel string * * @return the formula as an excel string * @exception FormulaException */ public String getFormula() throws FormulaException { if (formulaString == null) { FormulaParser fp = new FormulaParser (tokens, this, externalSheet, nameTable, getSheet().getWorkbook().getSettings()); fp.parse(); formulaString = fp.getFormula(); } return formulaString; }
/** * Adds this formula to the list of formulas, if it falls within * the bounds * * @param fr the formula record to test for membership of this group * @return TRUE if the formulas was added, FALSE otherwise */ public boolean add(BaseSharedFormulaRecord fr) { boolean added = false; int r = fr.getRow(); if (r >= firstRow && r <= lastRow) { int c = fr.getColumn(); if (c >= firstCol && c <= lastCol) { formulas.add(fr); added = true; } } return added; }