Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
d701a1a6
Kaydet (Commit)
d701a1a6
authored
Eki 22, 2014
tarafından
Stephan Bergmann
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Move virtual ScToken members up to FormulaToken
Change-Id: I20eb3b44d540f459cd1902a7a3b6a5c867e5bc07
üst
19d2f421
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
86 additions
and
92 deletions
+86
-92
token.cxx
formula/source/core/api/token.cxx
+65
-0
token.hxx
include/formula/token.hxx
+21
-0
token.hxx
sc/inc/token.hxx
+0
-27
token.cxx
sc/source/core/tool/token.cxx
+0
-65
No files found.
formula/source/core/api/token.cxx
Dosyayı görüntüle @
d701a1a6
...
...
@@ -254,6 +254,71 @@ void FormulaToken::SetError( sal_uInt16 )
SAL_WARN
(
"formula.core"
,
"FormulaToken::SetError: virtual dummy called"
);
}
const
ScSingleRefData
*
FormulaToken
::
GetSingleRef
()
const
{
OSL_FAIL
(
"FormulaToken::GetSingleRef: virtual dummy called"
);
return
nullptr
;
}
ScSingleRefData
*
FormulaToken
::
GetSingleRef
()
{
OSL_FAIL
(
"FormulaToken::GetSingleRef: virtual dummy called"
);
return
nullptr
;
}
const
ScComplexRefData
*
FormulaToken
::
GetDoubleRef
()
const
{
OSL_FAIL
(
"FormulaToken::GetDoubleRef: virtual dummy called"
);
return
nullptr
;
}
ScComplexRefData
*
FormulaToken
::
GetDoubleRef
()
{
OSL_FAIL
(
"FormulaToken::GetDoubleRef: virtual dummy called"
);
return
nullptr
;
}
const
ScSingleRefData
*
FormulaToken
::
GetSingleRef2
()
const
{
OSL_FAIL
(
"FormulaToken::GetSingleRef2: virtual dummy called"
);
return
nullptr
;
}
ScSingleRefData
*
FormulaToken
::
GetSingleRef2
()
{
OSL_FAIL
(
"FormulaToken::GetSingleRef2: virtual dummy called"
);
return
nullptr
;
}
const
ScMatrix
*
FormulaToken
::
GetMatrix
()
const
{
OSL_FAIL
(
"FormulaToken::GetMatrix: virtual dummy called"
);
return
NULL
;
}
ScMatrix
*
FormulaToken
::
GetMatrix
()
{
OSL_FAIL
(
"FormulaToken::GetMatrix: virtual dummy called"
);
return
NULL
;
}
ScJumpMatrix
*
FormulaToken
::
GetJumpMatrix
()
const
{
OSL_FAIL
(
"FormulaToken::GetJumpMatrix: virtual dummy called"
);
return
NULL
;
}
const
std
::
vector
<
ScComplexRefData
>*
FormulaToken
::
GetRefList
()
const
{
OSL_FAIL
(
"FormulaToken::GetRefList: virtual dummy called"
);
return
NULL
;
}
std
::
vector
<
ScComplexRefData
>*
FormulaToken
::
GetRefList
()
{
OSL_FAIL
(
"FormulaToken::GetRefList: virtual dummy called"
);
return
NULL
;
}
bool
FormulaToken
::
TextEqual
(
const
FormulaToken
&
rToken
)
const
{
return
*
this
==
rToken
;
...
...
include/formula/token.hxx
Dosyayı görüntüle @
d701a1a6
...
...
@@ -20,6 +20,10 @@
#ifndef INCLUDED_FORMULA_TOKEN_HXX
#define INCLUDED_FORMULA_TOKEN_HXX
#include <sal/config.h>
#include <vector>
#include <string.h>
#include <formula/opcode.hxx>
#include <tools/mempool.hxx>
...
...
@@ -29,6 +33,11 @@
#include <svl/sharedstring.hxx>
#include <osl/interlck.h>
class
ScJumpMatrix
;
class
ScMatrix
;
struct
ScComplexRefData
;
struct
ScSingleRefData
;
namespace
formula
{
...
...
@@ -154,6 +163,18 @@ public:
virtual
sal_uInt16
GetError
()
const
;
virtual
void
SetError
(
sal_uInt16
);
virtual
const
ScSingleRefData
*
GetSingleRef
()
const
;
virtual
ScSingleRefData
*
GetSingleRef
();
virtual
const
ScComplexRefData
*
GetDoubleRef
()
const
;
virtual
ScComplexRefData
*
GetDoubleRef
();
virtual
const
ScSingleRefData
*
GetSingleRef2
()
const
;
virtual
ScSingleRefData
*
GetSingleRef2
();
virtual
const
ScMatrix
*
GetMatrix
()
const
;
virtual
ScMatrix
*
GetMatrix
();
virtual
ScJumpMatrix
*
GetJumpMatrix
()
const
;
virtual
const
std
::
vector
<
ScComplexRefData
>*
GetRefList
()
const
;
virtual
std
::
vector
<
ScComplexRefData
>*
GetRefList
();
virtual
FormulaToken
*
Clone
()
const
{
return
new
FormulaToken
(
*
this
);
}
virtual
bool
TextEqual
(
const
formula
::
FormulaToken
&
rToken
)
const
;
...
...
sc/inc/token.hxx
Dosyayı görüntüle @
d701a1a6
...
...
@@ -62,33 +62,6 @@ protected:
public
:
virtual
~
ScToken
();
/**
Dummy methods to avoid switches and casts where possible,
the real token classes have to overload the appropriate method[s].
The only methods valid anytime if not overloaded are:
- GetByte() since this represents the count of parameters to a function
which of course is 0 on non-functions. formula::FormulaByteToken and ScExternal do
overload it.
- HasForceArray() since also this is only used for operators and
functions and is 0 for other tokens.
Any other non-overloaded method pops up an assertion.
*/
virtual
const
ScSingleRefData
*
GetSingleRef
()
const
;
virtual
ScSingleRefData
*
GetSingleRef
();
virtual
const
ScComplexRefData
*
GetDoubleRef
()
const
;
virtual
ScComplexRefData
*
GetDoubleRef
();
virtual
const
ScSingleRefData
*
GetSingleRef2
()
const
;
virtual
ScSingleRefData
*
GetSingleRef2
();
virtual
const
ScMatrix
*
GetMatrix
()
const
;
virtual
ScMatrix
*
GetMatrix
();
virtual
ScJumpMatrix
*
GetJumpMatrix
()
const
;
virtual
const
ScRefList
*
GetRefList
()
const
;
virtual
ScRefList
*
GetRefList
();
};
#if DEBUG_FORMULA_COMPILER
...
...
sc/source/core/tool/token.cxx
Dosyayı görüntüle @
d701a1a6
...
...
@@ -637,71 +637,6 @@ FormulaTokenRef extendRangeReference( FormulaToken & rTok1, FormulaToken & rTok2
return
FormulaTokenRef
(
xRes
.
get
());
}
const
ScSingleRefData
*
ScToken
::
GetSingleRef
()
const
{
OSL_FAIL
(
"ScToken::GetSingleRef: virtual dummy called"
);
return
nullptr
;
}
ScSingleRefData
*
ScToken
::
GetSingleRef
()
{
OSL_FAIL
(
"ScToken::GetSingleRef: virtual dummy called"
);
return
nullptr
;
}
const
ScComplexRefData
*
ScToken
::
GetDoubleRef
()
const
{
OSL_FAIL
(
"ScToken::GetDoubleRef: virtual dummy called"
);
return
nullptr
;
}
ScComplexRefData
*
ScToken
::
GetDoubleRef
()
{
OSL_FAIL
(
"ScToken::GetDoubleRef: virtual dummy called"
);
return
nullptr
;
}
const
ScSingleRefData
*
ScToken
::
GetSingleRef2
()
const
{
OSL_FAIL
(
"ScToken::GetSingleRef2: virtual dummy called"
);
return
nullptr
;
}
ScSingleRefData
*
ScToken
::
GetSingleRef2
()
{
OSL_FAIL
(
"ScToken::GetSingleRef2: virtual dummy called"
);
return
nullptr
;
}
const
ScMatrix
*
ScToken
::
GetMatrix
()
const
{
OSL_FAIL
(
"ScToken::GetMatrix: virtual dummy called"
);
return
NULL
;
}
ScMatrix
*
ScToken
::
GetMatrix
()
{
OSL_FAIL
(
"ScToken::GetMatrix: virtual dummy called"
);
return
NULL
;
}
ScJumpMatrix
*
ScToken
::
GetJumpMatrix
()
const
{
OSL_FAIL
(
"ScToken::GetJumpMatrix: virtual dummy called"
);
return
NULL
;
}
const
ScRefList
*
ScToken
::
GetRefList
()
const
{
OSL_FAIL
(
"ScToken::GetRefList: virtual dummy called"
);
return
NULL
;
}
ScRefList
*
ScToken
::
GetRefList
()
{
OSL_FAIL
(
"ScToken::GetRefList: virtual dummy called"
);
return
NULL
;
}
// real implementations of virtual functions
const
ScSingleRefData
*
ScSingleRefToken
::
GetSingleRef
()
const
{
return
&
aSingleRef
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment