|
LibreOffice Module sc (master) 1
|
#include <simpleformulacalc.hxx>
Public Member Functions | |
| ScSimpleFormulaCalculator (ScDocument &rDoc, const ScAddress &rAddr, const OUString &rFormula, bool bMatrixFormula, formula::FormulaGrammar::Grammar eGram=formula::FormulaGrammar::GRAM_DEFAULT) | |
| ~ScSimpleFormulaCalculator () | |
| void | Calculate () |
| bool | IsValue () |
| bool | IsMatrix () |
| FormulaError | GetErrCode () |
| double | GetValue () |
| svl::SharedString | GetString () |
| SvNumFormatType | GetFormatType () const |
| bool | HasColRowName () const |
| ScTokenArray * | GetCode () |
| void | SetLimitString (bool bLimitString) |
Private Attributes | |
| SvNumFormatType | mnFormatType |
| bool | mbCalculated |
| std::unique_ptr< ScTokenArray > | mpCode |
| ScAddress | maAddr |
| ScDocument & | mrDoc |
| ScFormulaResult | maResult |
| formula::FormulaGrammar::Grammar | maGram |
| bool | mbMatrixResult |
| OUString | maMatrixFormulaResult |
| bool | mbLimitString |
| bool | mbMatrixFormula |
Definition at line 21 of file simpleformulacalc.hxx.
| ScSimpleFormulaCalculator::ScSimpleFormulaCalculator | ( | ScDocument & | rDoc, |
| const ScAddress & | rAddr, | ||
| const OUString & | rFormula, | ||
| bool | bMatrixFormula, | ||
| formula::FormulaGrammar::Grammar | eGram = formula::FormulaGrammar::GRAM_DEFAULT |
||
| ) |
Definition at line 20 of file simpleformulacalc.cxx.
References ALL, ScCompiler::CompileString(), formula::FormulaCompiler::CompileTokenArray(), maAddr, mpCode, and mrDoc.
| ScSimpleFormulaCalculator::~ScSimpleFormulaCalculator | ( | ) |
Definition at line 38 of file simpleformulacalc.cxx.
| void ScSimpleFormulaCalculator::Calculate | ( | ) |
Definition at line 42 of file simpleformulacalc.cxx.
References ScInterpreter::AssertFormulaMatrix(), aStr, formula::FormulaCompiler::CreateStringFromToken(), DISPLAY_LEN, ScDocument::GetDocumentShell(), ScDocument::GetFormulaCell(), formula::FormulaCompiler::GetNativeSymbol(), ScDocument::GetNonThreadedContext(), ScInterpreter::GetResultToken(), ScInterpreter::GetRetFormatType(), i, ScInterpreter::Interpret(), maAddr, maGram, maMatrixFormulaResult, maResult, mbCalculated, mbLimitString, mbMatrixFormula, mbMatrixResult, mnFormatType, mpCode, mrDoc, n, ocArrayColSep, ocArrayRowSep, ScInterpreter::SetLinkManager(), ScFormulaResult::SetToken(), and formula::svMatrixCell.
Referenced by GetErrCode(), GetString(), GetValue(), IsMatrix(), and IsValue().
| ScTokenArray * ScSimpleFormulaCalculator::GetCode | ( | ) |
Definition at line 145 of file simpleformulacalc.cxx.
References mpCode.
| FormulaError ScSimpleFormulaCalculator::GetErrCode | ( | ) |
Definition at line 105 of file simpleformulacalc.cxx.
References Calculate(), ScFormulaResult::GetResultError(), maResult, and mpCode.
|
inline |
Definition at line 49 of file simpleformulacalc.hxx.
References mnFormatType.
| svl::SharedString ScSimpleFormulaCalculator::GetString | ( | ) |
Definition at line 126 of file simpleformulacalc.cxx.
References Calculate(), svl::SharedString::getEmptyString(), ScFormulaResult::GetResultError(), ScFormulaResult::GetString(), maMatrixFormulaResult, maResult, mbMatrixResult, and mpCode.
| double ScSimpleFormulaCalculator::GetValue | ( | ) |
Definition at line 115 of file simpleformulacalc.cxx.
References Calculate(), ScFormulaResult::GetDouble(), ScFormulaResult::GetResultError(), maResult, and mpCode.
| bool ScSimpleFormulaCalculator::HasColRowName | ( | ) | const |
Definition at line 140 of file simpleformulacalc.cxx.
References formula::FormulaTokenArrayPlainIterator::GetNextColRowName().
| bool ScSimpleFormulaCalculator::IsMatrix | ( | ) |
Definition at line 98 of file simpleformulacalc.cxx.
References Calculate(), and mbMatrixResult.
| bool ScSimpleFormulaCalculator::IsValue | ( | ) |
Definition at line 88 of file simpleformulacalc.cxx.
References Calculate(), ScFormulaResult::IsValue(), maResult, and mbMatrixResult.
| void ScSimpleFormulaCalculator::SetLimitString | ( | bool | bLimitString | ) |
Definition at line 150 of file simpleformulacalc.cxx.
References mbLimitString.
|
private |
Definition at line 28 of file simpleformulacalc.hxx.
Referenced by Calculate(), and ScSimpleFormulaCalculator().
|
private |
Definition at line 31 of file simpleformulacalc.hxx.
Referenced by Calculate().
|
private |
Definition at line 33 of file simpleformulacalc.hxx.
Referenced by Calculate(), and GetString().
|
private |
Definition at line 30 of file simpleformulacalc.hxx.
Referenced by Calculate(), GetErrCode(), GetString(), GetValue(), and IsValue().
|
private |
Definition at line 26 of file simpleformulacalc.hxx.
Referenced by Calculate().
|
private |
Definition at line 34 of file simpleformulacalc.hxx.
Referenced by Calculate(), and SetLimitString().
|
private |
Definition at line 35 of file simpleformulacalc.hxx.
Referenced by Calculate().
|
private |
Definition at line 32 of file simpleformulacalc.hxx.
Referenced by Calculate(), GetString(), IsMatrix(), and IsValue().
|
private |
Definition at line 24 of file simpleformulacalc.hxx.
Referenced by Calculate(), and GetFormatType().
|
private |
Definition at line 27 of file simpleformulacalc.hxx.
Referenced by Calculate(), GetCode(), GetErrCode(), GetString(), GetValue(), and ScSimpleFormulaCalculator().
|
private |
Definition at line 29 of file simpleformulacalc.hxx.
Referenced by Calculate(), and ScSimpleFormulaCalculator().