diff options
author | Eike Rathke <erack@redhat.com> | 2013-09-17 01:01:58 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2013-09-17 01:04:14 +0200 |
commit | 3ec486639befae454eebfd5b8f5dbc88aa357404 (patch) | |
tree | a6e7a15df8feadc7f033f5a04210025a8e9bdcd9 /include | |
parent | 24726fe2de005fe9532487907f8867259f61260c (diff) |
introduced putCopyOpCode() to handle copyFrom()
... and added bOverrideKnownBad handling
Change-Id: I1b669771ec1aa0cdfa1c1bef0bcfccfad96fe727
Diffstat (limited to 'include')
-rw-r--r-- | include/formula/FormulaCompiler.hxx | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/include/formula/FormulaCompiler.hxx b/include/formula/FormulaCompiler.hxx index 6e271ca15a4f..28bf5f928075 100644 --- a/include/formula/FormulaCompiler.hxx +++ b/include/formula/FormulaCompiler.hxx @@ -114,7 +114,14 @@ public: } virtual ~OpCodeMap(); - void copyFrom( const OpCodeMap& r ); + /** Copy mappings from r into this map, effectively replacing this map. + + @param bOverrideKnownBad + If TRUE, override known legacy bad function names with + correct ones if the conditions can be derived from the + current maps. + */ + void copyFrom( const OpCodeMap& r, bool bOverrideKnownBad ); /// Get the symbol String -> OpCode hash map for finds. inline const OpCodeHashMap* getHashMap() const { return mpHashMap; } @@ -180,6 +187,14 @@ public: /** The value used in createSequenceOfAvailableMappings() and thus in XFormulaOpCodeMapper::getMappings() for an unknown symbol. */ static sal_Int32 getOpCodeUnknown(); + + private: + + /** Conditionally put a mapping in copyFrom() context. + + Does NOT check eOp range! + */ + void putCopyOpCode( const String& rSymbol, OpCode eOp ); }; public: |