LibreOffice Module sc (master) 1
|
Each instance of this struct represents a single filtering criteria. More...
#include <queryentry.hxx>
Classes | |
struct | Item |
Public Types | |
enum | QueryType { ByValue , ByString , ByDate , ByEmpty , ByTextColor , ByBackgroundColor } |
typedef std::vector< Item > | QueryItemsType |
Public Member Functions | |
ScQueryEntry () | |
ScQueryEntry (const ScQueryEntry &r) | |
~ScQueryEntry () | |
utl::TextSearch * | GetSearchTextPtr (utl::SearchParam::SearchType eSearchType, bool bCaseSens, bool bWildMatchSel) const |
creates pSearchParam and pSearchText if necessary More... | |
QueryItemsType & | GetQueryItems () |
const QueryItemsType & | GetQueryItems () const |
void | SetQueryByEmpty () |
bool | IsQueryByEmpty () const |
void | SetQueryByNonEmpty () |
bool | IsQueryByNonEmpty () const |
void | SetQueryByTextColor (Color color) |
bool | IsQueryByTextColor () const |
void | SetQueryByBackgroundColor (Color color) |
bool | IsQueryByBackgroundColor () const |
const Item & | GetQueryItem () const |
Item & | GetQueryItem () |
void | Clear () |
ScQueryEntry & | operator= (const ScQueryEntry &r) |
bool | operator== (const ScQueryEntry &r) const |
Public Attributes | |
bool | bDoQuery |
SCCOLROW | nField |
ScQueryOp | eOp |
ScQueryConnect | eConnect |
std::unique_ptr< utl::SearchParam > | pSearchParam |
if Wildcard or RegExp, not saved More... | |
std::unique_ptr< utl::TextSearch > | pSearchText |
if Wildcard or RegExp, not saved More... | |
Private Member Functions | |
Item & | GetQueryItemImpl () const |
Private Attributes | |
QueryItemsType | maQueryItems |
Stores all query items. More... | |
Each instance of this struct represents a single filtering criteria.
Definition at line 33 of file queryentry.hxx.
typedef std::vector<Item> ScQueryEntry::QueryItemsType |
Definition at line 58 of file queryentry.hxx.
Enumerator | |
---|---|
ByValue | |
ByString | |
ByDate | |
ByEmpty | |
ByTextColor | |
ByBackgroundColor |
Definition at line 35 of file queryentry.hxx.
ScQueryEntry::ScQueryEntry | ( | ) |
Definition at line 41 of file queryentry.cxx.
ScQueryEntry::ScQueryEntry | ( | const ScQueryEntry & | r | ) |
Definition at line 50 of file queryentry.cxx.
ScQueryEntry::~ScQueryEntry | ( | ) |
Definition at line 59 of file queryentry.cxx.
void ScQueryEntry::Clear | ( | ) |
Definition at line 171 of file queryentry.cxx.
References bDoQuery, eConnect, eOp, maQueryItems, nField, pSearchParam, pSearchText, SC_AND, and SC_EQUAL.
Referenced by ScTable::CreateQueryParam(), and ScDBData::MoveTo().
|
inline |
Definition at line 86 of file queryentry.hxx.
|
inline |
Definition at line 85 of file queryentry.hxx.
Referenced by ScQueryCellIteratorBase< accessType, queryType >::BinarySearch(), ScInterpreter::CalculateLookup(), sc::CompareFunc(), ScTable::CreateQueryParam(), ScTable::CreateStarQuery(), ScXMLConditionContext::endFastElement(), ScXMLDPConditionContext::endFastElement(), ScInterpreter::FillEntry(), ScQueryParamBase::FillInExcelSyntax(), ScCountIfCellIterator< ScQueryCellIteratorAccess::SortedCache >::GetCount(), ScInterpreter::GetDBParams(), ScPivotFilterDlg::GetOutputItem(), IMPL_LINK(), ScFilterDlg::Init(), ScPivotFilterDlg::Init(), ScDBQueryDataIterator::DataAccessMatrix::isValidQuery(), ScInterpreter::IterateParametersIf(), ScInterpreter::IterateParametersIfs(), lcl_getPrevRowWithEmptyValueLookup(), ScSortedRangeCache::makeHashKey(), ScQueryCellIteratorBase< accessType, queryType >::PerformQuery(), ScLookupCache::QueryCriteria::QueryCriteria(), ScInterpreter::QueryMat(), XclImpAutoFilterData::ReadAutoFilter(), ScFilterDlg::RefreshEditRow(), ScInterpreter::ScCountIf(), ScInterpreter::ScLookup(), ScInterpreter::ScMatch(), ScQueryCellIteratorBase< accessType, queryType >::ScQueryCellIteratorBase(), ScSheetDPData::ScSheetDPData(), ScSortedRangeCache::ScSortedRangeCache(), toValueType(), ScGridWindow::UpdateAutoFilterFromMenu(), ScFilterDlg::UpdateColorList(), ScDPCache::ValidQuery(), and ScXMLExportDataPilot::WriteDPCondition().
|
private |
Definition at line 163 of file queryentry.cxx.
References maQueryItems.
|
inline |
Definition at line 75 of file queryentry.hxx.
Referenced by XclExpAutofilter::AddColorEntry(), XclExpAutofilter::AddEntry(), XclExpAutofilter::AddMultiValueEntry(), sc::CompareFunc(), ScDBQueryDataIterator::DataAccessInternal::DataAccessInternal(), ScXMLConditionContext::endFastElement(), ScCellRangeObj::filter(), ScFilterDescriptorBase::getFilterFields(), ScFilterDescriptorBase::getFilterFields2(), ScFilterDescriptorBase::getFilterFields3(), ScInterpreter::IterateParametersIfs(), ScGridWindow::LaunchAutoFilterMenu(), ScSortedRangeCache::makeHashKey(), ScQueryCellIteratorBase< accessType, queryType >::PerformQuery(), ScQueryEvaluator::processEntry(), XclImpAutoFilterData::ReadAutoFilter(), ScSortedRangeCache::ScSortedRangeCache(), ScFilterDescriptorBase::setFilterFields(), ScTable::TopTenQuery(), toValueType(), and ScGridWindow::UpdateAutoFilterFromMenu().
|
inline |
Definition at line 76 of file queryentry.hxx.
utl::TextSearch * ScQueryEntry::GetSearchTextPtr | ( | utl::SearchParam::SearchType | eSearchType, |
bool | bCaseSens, | ||
bool | bWildMatchSel | ||
) | const |
creates pSearchParam and pSearchText if necessary
Definition at line 194 of file queryentry.cxx.
References aStr, ScGlobal::getCharClass(), maQueryItems, pSearchParam, and pSearchText.
Referenced by ScQueryEvaluator::compareByString(), sc::CompareFunc(), and ScDPCache::ValidQuery().
bool ScQueryEntry::IsQueryByBackgroundColor | ( | ) | const |
Definition at line 153 of file queryentry.cxx.
References ByBackgroundColor, eOp, maQueryItems, ScQueryEntry::Item::meType, and SC_EQUAL.
Referenced by XclExpAutofilter::AddEntry(), ScFilterDlg::Init(), and ScFilterDlg::RefreshEditRow().
bool ScQueryEntry::IsQueryByEmpty | ( | ) | const |
Definition at line 87 of file queryentry.cxx.
References ByEmpty, eOp, svl::SharedString::isEmpty(), maQueryItems, ScQueryEntry::Item::maString, ScQueryEntry::Item::meType, ScQueryEntry::Item::mfVal, SC_EMPTYFIELDS, and SC_EQUAL.
Referenced by XclExpAutofilter::AddEntry(), ScFilterDescriptorBase::getFilterFields(), ScFilterDescriptorBase::getFilterFields2(), ScFilterDescriptorBase::getFilterFields3(), ScFilterDlg::Init(), ScPivotFilterDlg::Init(), ScInterpreter::IterateParametersIfs(), ScQueryEvaluator::processEntry(), ScFilterDlg::RefreshEditRow(), ScDPCache::ValidQuery(), and ScXMLExportDataPilot::WriteDPCondition().
bool ScQueryEntry::IsQueryByNonEmpty | ( | ) | const |
Definition at line 109 of file queryentry.cxx.
References ByEmpty, eOp, svl::SharedString::isEmpty(), maQueryItems, ScQueryEntry::Item::maString, ScQueryEntry::Item::meType, ScQueryEntry::Item::mfVal, SC_EQUAL, and SC_NONEMPTYFIELDS.
Referenced by XclExpAutofilter::AddEntry(), ScFilterDescriptorBase::getFilterFields(), ScFilterDescriptorBase::getFilterFields2(), ScFilterDescriptorBase::getFilterFields3(), ScFilterDlg::Init(), ScPivotFilterDlg::Init(), ScQueryEvaluator::processEntry(), ScFilterDlg::RefreshEditRow(), ScDPCache::ValidQuery(), and ScXMLExportDataPilot::WriteDPCondition().
bool ScQueryEntry::IsQueryByTextColor | ( | ) | const |
Definition at line 132 of file queryentry.cxx.
References ByTextColor, eOp, maQueryItems, ScQueryEntry::Item::meType, and SC_EQUAL.
Referenced by XclExpAutofilter::AddEntry(), ScFilterDlg::Init(), and ScFilterDlg::RefreshEditRow().
ScQueryEntry & ScQueryEntry::operator= | ( | const ScQueryEntry & | r | ) |
Definition at line 63 of file queryentry.cxx.
References bDoQuery, eConnect, eOp, maQueryItems, nField, pSearchParam, and pSearchText.
bool ScQueryEntry::operator== | ( | const ScQueryEntry & | r | ) | const |
Definition at line 184 of file queryentry.cxx.
References bDoQuery, eConnect, eOp, maQueryItems, and nField.
void ScQueryEntry::SetQueryByBackgroundColor | ( | Color | color | ) |
Definition at line 142 of file queryentry.cxx.
References ByBackgroundColor, eOp, ScQueryEntry::Item::maColor, maQueryItems, ScQueryEntry::Item::maString, ScQueryEntry::Item::meType, ScQueryEntry::Item::mfVal, SC_BACKGROUNDCOLOR, and SC_EQUAL.
Referenced by IMPL_LINK().
void ScQueryEntry::SetQueryByEmpty | ( | ) |
Definition at line 77 of file queryentry.cxx.
References ByEmpty, eOp, maQueryItems, ScQueryEntry::Item::maString, ScQueryEntry::Item::meType, ScQueryEntry::Item::mfVal, SC_EMPTYFIELDS, and SC_EQUAL.
Referenced by ScXMLDPConditionContext::endFastElement(), ScQueryParamBase::FillInExcelSyntax(), ScXMLConditionContext::GetOperator(), ScPivotFilterDlg::GetOutputItem(), IMPL_LINK(), XclImpAutoFilterData::ReadAutoFilter(), ScFilterDescriptorBase::setFilterFields(), and ScGridWindow::UpdateAutoFilterFromMenu().
void ScQueryEntry::SetQueryByNonEmpty | ( | ) |
Definition at line 99 of file queryentry.cxx.
References ByEmpty, eOp, maQueryItems, ScQueryEntry::Item::maString, ScQueryEntry::Item::meType, ScQueryEntry::Item::mfVal, SC_EQUAL, and SC_NONEMPTYFIELDS.
Referenced by ScXMLDPConditionContext::endFastElement(), ScQueryParamBase::FillInExcelSyntax(), ScXMLConditionContext::GetOperator(), ScPivotFilterDlg::GetOutputItem(), IMPL_LINK(), XclImpAutoFilterData::ReadAutoFilter(), ScFilterDescriptorBase::setFilterFields(), and ScGridWindow::UpdateAutoFilterFromMenu().
void ScQueryEntry::SetQueryByTextColor | ( | Color | color | ) |
Definition at line 121 of file queryentry.cxx.
References ByTextColor, eOp, ScQueryEntry::Item::maColor, maQueryItems, ScQueryEntry::Item::maString, ScQueryEntry::Item::meType, ScQueryEntry::Item::mfVal, SC_EQUAL, and SC_TEXTCOLOR.
Referenced by IMPL_LINK().
bool ScQueryEntry::bDoQuery |
Definition at line 60 of file queryentry.hxx.
Referenced by ScXMLDPFilterContext::AddFilterField(), ScVbaRange::AutoFilter(), ScInterpreter::CalculateLookup(), Clear(), ScCellRangeObj::createFilterDescriptor(), ScCellRangeObj::createFilterDescriptorByObject(), ScTable::CreateStarQuery(), ScDBQueryDataIterator::DataAccessInternal::DataAccessInternal(), ScGridWindow::DrawButtons(), XclImpAutoFilterData::EnableRemoveFilter(), ScXMLConditionContext::endFastElement(), ExcAutoFilterRecs::ExcAutoFilterRecs(), ScCellShell::ExecuteDB(), ScQueryParamBase::FillInExcelSyntax(), ScCellRangeObj::filter(), ScQueryCellIterator< accessType >::FindEqualOrSortedLastInRange(), ScInterpreter::GetDBParams(), ScCellShell::GetDBState(), ScFilterDescriptorBase::getFilterFields(), ScFilterDescriptorBase::getFilterFields2(), ScFilterDescriptorBase::getFilterFields3(), ScQueryCellIterator< ScQueryCellIteratorAccess::SortedCache >::GetNext(), ScDBData::GetOperations(), ScPivotFilterDlg::GetOutputItem(), ScDatabaseRangeObj::GetQueryParam(), IMPL_LINK(), ScFilterDlg::Init(), ScPivotFilterDlg::Init(), ScGridWindow::IsAutoFilterActive(), ScDBQueryDataIterator::DataAccessMatrix::isValidQuery(), ScInterpreter::IterateParametersIf(), ScInterpreter::IterateParametersIfs(), ScSortedRangeCache::makeHashKey(), ScDBData::MoveTo(), operator=(), operator==(), ScDBDocFunc::Query(), XclImpAutoFilterData::ReadAutoFilter(), ScFilterDlg::RefreshEditRow(), ScDBFunc::RepeatDB(), ScDBDocFunc::RepeatDB(), ScInterpreter::ScCountIf(), ScInterpreter::ScLookup(), ScInterpreter::ScMatch(), ScSheetDPData::ScSheetDPData(), ScSortedRangeCache::ScSortedRangeCache(), ScFilterDescriptorBase::setFilterFields(), ScDatabaseRangeObj::SetQueryParam(), ScDBDocFunc::Sort(), ScDBFunc::ToggleAutoFilter(), ScTable::TopTenQuery(), toValueType(), ScGridWindow::UpdateAutoFilterFromMenu(), ScDPObject::UpdateReference(), ScDPCache::ValidQuery(), ScQueryEvaluator::ValidQuery(), and ScXMLExportDataPilot::WriteDPFilter().
ScQueryConnect ScQueryEntry::eConnect |
Definition at line 63 of file queryentry.hxx.
Referenced by XclExpAutofilter::AddEntry(), Clear(), ScTable::CreateExcelQuery(), ScTable::CreateStarQuery(), ScXMLConditionContext::endFastElement(), ScXMLDPConditionContext::endFastElement(), ExcAutoFilterRecs::ExcAutoFilterRecs(), ScDocument::GetFilterEntries(), ScFilterDescriptorBase::getFilterFields(), ScPivotFilterDlg::GetOutputItem(), ScFilterDlg::Init(), ScPivotFilterDlg::Init(), ScGridWindow::IsAutoFilterActive(), ScDBQueryDataIterator::DataAccessMatrix::isValidQuery(), operator=(), operator==(), XclImpAutoFilterData::ReadAutoFilter(), ScFilterDlg::RefreshEditRow(), ScFilterDescriptorBase::setFilterFields(), ScGridWindow::UpdateAutoFilterFromMenu(), ScDPCache::ValidQuery(), ScQueryEvaluator::ValidQuery(), and ScXMLExportDataPilot::WriteDPFilter().
ScQueryOp ScQueryEntry::eOp |
Definition at line 62 of file queryentry.hxx.
Referenced by XclExpAutofilter::AddEntry(), ScQueryCellIteratorBase< accessType, queryType >::BinarySearch(), ScInterpreter::CalculateLookup(), Clear(), ScQueryEvaluator::compareByRangeLookup(), ScQueryEvaluator::compareByString(), ScQueryEvaluator::compareByValue(), sc::CompareFunc(), sc::CompareOptions::CompareOptions(), ScTable::CreateStarQuery(), ScXMLDPConditionContext::endFastElement(), ExcelQueryToOooQuery(), ScQueryParamBase::FillInExcelSyntax(), ScQueryCellIterator< accessType >::FindEqualOrSortedLastInRange(), ScCountIfCellIterator< ScQueryCellIteratorAccess::SortedCache >::GetCount(), ScFilterDescriptorBase::getFilterFields(), ScXMLConditionContext::GetOperator(), ScPivotFilterDlg::GetOutputItem(), IMPL_LINK(), ScFilterDlg::Init(), ScPivotFilterDlg::Init(), ScQueryEvaluator::isFastCompareByString(), IsQueryByBackgroundColor(), IsQueryByEmpty(), IsQueryByNonEmpty(), IsQueryByTextColor(), ScQueryEvaluator::isRealWildOrRegExp(), ScQueryEvaluator::isTestWildOrRegExp(), ScDBQueryDataIterator::DataAccessMatrix::isValidQuery(), ScInterpreter::IterateParametersIf(), ScInterpreter::IterateParametersIfs(), ScGridWindow::LaunchAutoFilterMenu(), lcl_LookupQuery(), ScSortedRangeCache::makeHashKey(), operator=(), operator==(), ScQueryEvaluator::processEntry(), ScLookupCache::QueryCriteria::QueryCriteria(), ScInterpreter::QueryMat(), XclImpAutoFilterData::ReadAutoFilter(), ScFilterDlg::RefreshEditRow(), ScInterpreter::ScCountIf(), ScInterpreter::ScLookup(), ScInterpreter::ScMatch(), ScSortedRangeCache::ScSortedRangeCache(), ScFilterDescriptorBase::setFilterFields(), SetQueryByBackgroundColor(), SetQueryByEmpty(), SetQueryByNonEmpty(), SetQueryByTextColor(), ScTable::TopTenQuery(), ScGridWindow::UpdateAutoFilterFromMenu(), ScDPCache::ValidQuery(), and ScXMLExportDataPilot::WriteDPCondition().
|
mutableprivate |
Stores all query items.
It must contain at least one item at all times (for single equality match queries or comparative queries). It may contain multiple items for multi-equality match queries.
Definition at line 99 of file queryentry.hxx.
Referenced by Clear(), GetQueryItemImpl(), GetSearchTextPtr(), IsQueryByBackgroundColor(), IsQueryByEmpty(), IsQueryByNonEmpty(), IsQueryByTextColor(), operator=(), operator==(), SetQueryByBackgroundColor(), SetQueryByEmpty(), SetQueryByNonEmpty(), and SetQueryByTextColor().
SCCOLROW ScQueryEntry::nField |
Definition at line 61 of file queryentry.hxx.
Referenced by ScVbaRange::AutoFilter(), ScInterpreter::CalculateLookup(), Clear(), ScTable::CreateExcelQuery(), ScCellRangeObj::createFilterDescriptor(), ScCellRangeObj::createFilterDescriptorByObject(), ScTable::CreateStarQuery(), ScGridWindow::DrawButtons(), ScXMLConditionContext::endFastElement(), ScXMLDPConditionContext::endFastElement(), ExcAutoFilterRecs::ExcAutoFilterRecs(), ScCellRangeObj::filter(), ScQueryCellIterator< accessType >::FindEqualOrSortedLastInRange(), ScFilterDescriptorBase::getFilterFields(), ScQueryCellIterator< ScQueryCellIteratorAccess::SortedCache >::GetNext(), ScPivotFilterDlg::GetOutputItem(), ScDatabaseRangeObj::GetQueryParam(), IMPL_LINK(), ScFilterDlg::Init(), ScPivotFilterDlg::Init(), ScGridWindow::IsAutoFilterActive(), ScDBQueryDataIterator::DataAccessMatrix::isValidQuery(), ScInterpreter::IterateParametersIf(), ScInterpreter::IterateParametersIfs(), ScInterpreter::LookupQueryWithCache(), ScDBData::MoveTo(), operator=(), operator==(), ScQueryCellIteratorBase< accessType, queryType >::PerformQuery(), ScQueryEvaluator::processEntry(), XclImpAutoFilterData::ReadAutoFilter(), ScFilterDlg::RefreshEditRow(), ScInterpreter::ScCountIf(), ScInterpreter::ScLookup(), ScInterpreter::ScMatch(), ScFilterDescriptorBase::setFilterFields(), ScDatabaseRangeObj::SetQueryParam(), ScTable::TopTenQuery(), ScGridWindow::UpdateAutoFilterFromMenu(), ScDPObject::UpdateReference(), ScDPCache::ValidQuery(), ScQueryEvaluator::ValidQuery(), and ScXMLExportDataPilot::WriteDPCondition().
|
mutable |
if Wildcard or RegExp, not saved
Definition at line 64 of file queryentry.hxx.
Referenced by Clear(), GetSearchTextPtr(), and operator=().
|
mutable |
if Wildcard or RegExp, not saved
Definition at line 65 of file queryentry.hxx.
Referenced by Clear(), GetSearchTextPtr(), and operator=().