summaryrefslogtreecommitdiffstats
path: root/sc/inc/queryparam.hxx
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@suse.com>2011-11-03 22:57:31 -0400
committerKohei Yoshida <kohei.yoshida@suse.com>2011-11-04 22:40:27 -0400
commitd6edecd37c4fe71cdb7aea313ac1c7478c7920e4 (patch)
tree0e6ec8cba35f291f78f73bb1da66ce0b4be1a1c5 /sc/inc/queryparam.hxx
parentconst correct ness etc & mutable only for lazy-initializing accessor. (diff)
downloadcore-d6edecd37c4fe71cdb7aea313ac1c7478c7920e4.tar.gz
core-d6edecd37c4fe71cdb7aea313ac1c7478c7920e4.zip
Moved ScQueryEntry out of global.?xx to queryparam.?xx.
This is more appropriate.
Diffstat (limited to 'sc/inc/queryparam.hxx')
-rw-r--r--sc/inc/queryparam.hxx39
1 files changed, 39 insertions, 0 deletions
diff --git a/sc/inc/queryparam.hxx b/sc/inc/queryparam.hxx
index a083f74acb9c..105a80180588 100644
--- a/sc/inc/queryparam.hxx
+++ b/sc/inc/queryparam.hxx
@@ -34,8 +34,47 @@
#include <vector>
+/*
+ * dialog returns the special field values "empty"/"not empty"
+ * as constants SC_EMPTYFIELDS and SC_NONEMPTYFIELDS respectively in nVal in
+ * conjuctions with the flag bQueryByString = FALSE.
+ */
+
+#define SC_EMPTYFIELDS ((double)0x0042)
+#define SC_NONEMPTYFIELDS ((double)0x0043)
+
struct ScDBQueryParamInternal;
+namespace utl {
+ class SearchParam;
+ class TextSearch;
+}
+
+struct ScQueryEntry
+{
+ bool bDoQuery;
+ bool bQueryByString;
+ bool bQueryByDate;
+ SCCOLROW nField;
+ ScQueryOp eOp;
+ ScQueryConnect eConnect;
+ String* pStr;
+ double nVal;
+ mutable utl::SearchParam* pSearchParam; // if RegExp, not saved
+ mutable utl::TextSearch* pSearchText; // if RegExp, not saved
+
+ ScQueryEntry();
+ ScQueryEntry(const ScQueryEntry& r);
+ ~ScQueryEntry();
+
+ // creates pSearchParam and pSearchText if necessary, always RegExp!
+ utl::TextSearch* GetSearchTextPtr( bool bCaseSens ) const;
+
+ void Clear();
+ ScQueryEntry& operator=( const ScQueryEntry& r );
+ bool operator==( const ScQueryEntry& r ) const;
+};
+
struct ScQueryParamBase
{
bool bHasHeader;